Created
May 13, 2013 11:56
-
-
Save vishalsodani/5567806 to your computer and use it in GitHub Desktop.
More elegant use of counter
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
from collections import Counter | |
some_data = ['a','b','v','c','l','c'] | |
result = Counter(some_data) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment