in reply to Perl sort

In addition to the error pointed by Corion, I don't think you are trying to sort with the right items in the array reference you are building.

Assuming one line of your file contains something like:

12\t45
your first map:
map {chomp;[$_,split(/\t/)]}
will transform this line into:
["12\t45", 12, 45]
With such data, comparing:
$a->[0] <=> $b->[0] || $a->[1] <=> $b->[1]
in your sort code block makes little sense.

I would assume you probably want something like:

$a->[1] <=> $b->[1] or $a->[2] <=> $b->[2]