Python How To: Group and Count with Dictionaries
codefisher.org