my @files = <*.txt>; @files = map { $_->[0] } sort { $b->[1] <=> $a->[1] } map { [ $_, (-M $_) ] } @files;