http://www.perlmonks.org?node_id=121053


in reply to Re: Getting impossible things right (behaviour of keys)
in thread Getting impossible things right (behaviour of keys)

Or even:
foreach my $suffic( sort { length($b) <=> length($a) or $a cmp $b } keys %sufdata)
to sort both on length and alphanumeric