my @AoA=([11,1],[22,2],[11,1],[44,4]); my %h; $h{$_->[0]} = $_->[1] for @AoA; print qq($_ -> $h{$_}\n) for sort keys %h --Output--- 11 -> 1 22 -> 2 44 -> 4