Think about Loose Coupling | |
PerlMonks |
Re: replace specical char ^@ to empty charby Anonymous Monk |
on Nov 07, 2011 at 12:15 UTC ( [id://936486]=note: print w/replies, xml ) | Need Help?? |
If the two-character string "^@" actually does appear in the file, rather than being a representation of a null, then you would need to escape each character in the pattern, and use a grouping to indicate that the pair of characters may repeat: s/(?:\^\@)+$//g
In Section
Seekers of Perl Wisdom
|
|