in reply to file ext counter.
sub sort_by_value { my $hash = shift; sort {$hash->{$a} <=> $hash->{$b} } keys %$hash; } [download]