⭐ in reply to How do I remove control characters?
Try perldoc perlop and look for the transliteration operator.
Note: you may have to binmode the filehandle, depending on your OS.
The 'c' option means complement the range.tr/\040-\176/ /c;
Note: you may have to binmode the filehandle, depending on your OS.
In Section
Seekers of Perl Wisdom