Perl-Sensitive Sunglasses | |
PerlMonks |
Re: Hella sortby Abigail (Deacon) |
on Jul 03, 2001 at 04:55 UTC ( [id://93379]=note: print w/replies, xml ) | Need Help?? |
You use
which is wrong in various ways. First of all, =~ binds variables to regular expressions, substitutions or transliterations. split however splits its second parameter, or $_ if that parameter is not present. Second, split /./ doesn't split on periods. It splits on anything that isn't a newline. You want split /\./ here, that splits on a period. -- Abigail
In Section
Seekers of Perl Wisdom
|
|