I am trying to read the words in a File looks its not working as expected. Can you please let me know if I am missing anything.
from collections import Counter
wordcount=Counter(f1.read())
for k,v in wordcount.items():
print (k ,v)
File contents are:
DELETE
INSERT
DELETE
INSERT
UPDATE
UPDATE
Expecting
DELETE 2
INSERT 2 ..
..
but it is counting the letters