This will sort by count in reverse numerical order, from biggest count to smallest. If you want it the other way round, swap the $a and $b.for my $auth (sort { $hash{$b}{count} <=> $hash{$a}{count} } keys +%hash) { print FILE "$hash{$auth}{fname} $hash{$auth}{lname}: $hash{$au +th}{count}\n"; }
In reply to Re: problems sorting hashes of hashes
by btrott
in thread problems sorting hashes of hashes
by Anonymous Monk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |