Created
June 2, 2015 21:59
-
-
Save NotTheEconomist/f7a3c8a5d8837f12faba to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# assuming you've already populated d as | |
# d = {"pdf": ... } or whatever | |
from operator import itemgetter | |
print("Extension | Count") | |
for key,val in sorted(d.items(), key=itemgetter(1), reverse=True): | |
print("{:>9} | {}".format(key, val)) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment