Guest User

Untitled

a guest
Apr 26th, 2018
59
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.21 KB | None | 0 0
  1. dictionary = {}
  2.  
  3. for item in text_string:
  4. if item in dictionary:
  5. dictionary[item] = dictionary[item]+1
  6. else:
  7. dictionary[item] = 1
  8. print(dictionary)
  9.  
  10. text_string = text_string.split()
Add Comment
Please, Sign In to add comment