The following sorts numerically by the number preceeding the 'x', then numerically by the number following the 'x':
@a = sort { my ($a1, $a2) = split(/x/, $a); my ($b1, $b2) = split(/x/, $b); $a1 <=> $b1 || $a2 <=> $b2 } @a;
In reply to Re: how to sort this?
by ikegami
in thread how to sort this?
by sen
For: | Use: | ||
& | & | ||
< | < | ||
> | > | ||
[ | [ | ||
] | ] |