$_ = "Goodbye\\; Good luck\\, and thanks for all the fish!\\\n\\\n"; print "<$_>\n"; s/\\([;,\n])/$+/g; # Does work print "<$_>\n"; #### $_ = "Goodbye\\; Good luck\\, and thanks for all the fish!\\n\\n"; print qq{<$_>\n}; s/(\\.)/qq{"$1"}/eeg; print qq{<$_>\n};