in reply to Re: Find and Replace with special characters
in thread Find and Replace with special characters

You also want to make up your mind on whether @lines is being modified in place. If so, then you don't need @newlines at all and it's just
s/#(?=<-\(0N<-\(s3T)/*/g foreach ( @lines );
Otherwise, if you need to keep both versions around, then it's
@newlines = map { s/#(?=<-\(0N<-\(s3T)/*/gr } @lines;
(it being somewhat more efficient to allocate @newlines in one swell foop).