in reply to Re^2: Sorting filenames with custom function
in thread Sorting filenames with custom function
my $re = qr/\d+/; print join "\n", sort {($a =~ /$re/g)[-1] <=> ($b =~ /$re/g)[-1]; } @n +ames
But then I'd have to link to perlretut and Regexp Quote Like Operators as well...
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^4: Sorting filenames with custom function
by AnomalousMonk (Archbishop) on May 14, 2010 at 02:06 UTC |