http://www.perlmonks.org?node_id=205361


in reply to How to make only two of three substitutions?

you can always read the next line after your long line by:
$line = <FILE>; ### this will give you the first / that you want to +preserve
and remove any / after it using the regexp you mentioned

Hotshot