Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- message = 'it was a bright cold day in April, and the clocks were striking 13'
- dictionary = {}
- for i in message:
- dictionary.setdefault(i, 0)
- dictionary[i] = dictionary[i] + 1
- print dictionary
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement