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


in reply to How to compare hash values within the same hash?

You already have good answers. TIMTOWTDI:

# Frequency of each value. my %freq; $freq{$_}++ for values %hash; # Sort by frequency. my @bucket; @bucket[values %freq] = keys %freq; print "There are $#bucket occurrences of the value $bucket[-1].\n";