in reply to Re^2: input special characters
in thread input special characters
I'm not sure what the issue is, then. Take this snippet of code:
chomp(my $sep = <>); say join $sep, @data;
if I run this (with the above @data) and input a tab character, I do indeed get the output separated by tabs. Or do you want to be able to input the characters "\t" and have them interpreted as a tab, rather than a literal backslash followed by a literal lower-case t? In that case, you can use a regular expression to transform your separator:
chomp(my $sep = <>); $sep =~ s/\\t/\t/g; say join $sep, @data;
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^4: input special characters
by kepler (Scribe) on Jul 13, 2014 at 12:44 UTC | |
by AppleFritter (Vicar) on Jul 13, 2014 at 15:09 UTC |