laziness, impatience, and hubris | |
PerlMonks |
Re: sorting questionby kabel (Chaplain) |
on Nov 21, 2002 at 06:14 UTC ( [id://214714]=note: print w/replies, xml ) | Need Help?? |
for short: the split accepts a regexp as first parameter, wherein the | is a metasymbol, and you did NOT quote it properly ... ;)
note further that cmp does NOT work for numerics, or look for yourself what is going wrong :) you need the <=> operator to do numeric sorting in this way. and you saw the characters "ST" or "schwartzian transform" along with the code? ;) HTH UPDATE: added ST line
In Section
Seekers of Perl Wisdom
|
|