So do I understand correctly your input file contains literal backslashes followed by a letter, and not the control characters themselves?
IMO the best way to do this is make the replacements yourself, e.g. $string =~ s/\\n/\n/g; $string =~ s/\\t/\t/g; (Update before posting: as choroba just showed too). There are of course other ways (trickery with eval, which should be considered unsafe, or CPAN modules), but if it's just those two characters, doing the replacement yourself is probably easiest. Note those regexes don't take into account multiple backslashes, that is, if your input contains \\n or \\\\n - you'd have to show us more sample input if that is the case.
In reply to Re: print tab within an element of an array
by haukex
in thread print tab within an element of an array
by oldmonk201
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |