No problem, just throw an extra comparison in the sort block as documented in perldoc -f sort:
sort { $values{$a} <=> $values{$b} || $a cmp $b } keys %valuesIn reply to Re: Re: Re: hashes sorted by value, but displaying both keys and values
by chromatic
in thread hashes sorted by value, but displaying both keys and values
by Anonymous Monk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |