Rob Dixon wrote:
my @data = map { tr/%//d; [split] } split /\n/, $str;
A little late maybe, but...
Why do you have the second (in the order of operation) split operator in brackets? Shouldn't it just split $_ on whitespace if no arguments are given?
The brackets create an array reference and fill it with the contents of the second split. One array ref per line of the original split. Rob is building an array of arrays here, with plenty of shortcuts. ;) Make sense?
James
-- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] <http://learn.perl.org/> <http://learn.perl.org/first-response>