Skip to content

Instantly share code, notes, and snippets.

@zolizoli
Created October 30, 2010 19:57
@something=("in","a","bed","in","the","room","is","the");
foreach $string (@something) {
++$counts{$string};
}
foreach $key (sort {$counts {$a} <=> $counts{$b}} keys %counts) {
print "$key\t$counts)$key}\n";
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment