update: and now even simpler:use Sort::Key::Maker iikeysort => qw(integer integer); @sorted = iikeysort { /^(\d+)x(\d+)$/ } @a;
or if the chars between the two numbers can vary:use Sort::Key::Multi 'iikeysort'; @sorted = iikeysort { /^(\d+)x(\d+)$/ } @a;
use Sort::Key::Multi 'isikeysort'; @sorted = isikeysort { /^(\d+)(\w+)(\d+)$/ } @a;
In reply to Re: how to sort this?
by salva
in thread how to sort this?
by sen
For: | Use: | ||
& | & | ||
< | < | ||
> | > | ||
[ | [ | ||
] | ] |