in reply to sort by a multiple columns

Simple and works for variety of elements, to the best of knowledge
my @un_sorted = ([3,4,23,4,5],[3,4,56,2,4],[2,3,43,5,3],[2,3,43,6],[3, +4],[1,7,99,204],[1],[4,12],[110,99], [1111,19], [99]); @un_sorted = sort { $a->[0] <=> $b->[0] } @un_sorted;