sort { $hash{$a}->[2] cmp $hash{$b}->[2] } keys %hash