Advertisement
Guest User

Untitled

a guest
Jun 18th, 2019
76
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.19 KB | None | 0 0
  1. n, m = input().split()
  2. words = {}
  3. point = [0]*int(n)
  4. for i in range(int(m)):
  5.     t, w = input().split()
  6.     words[w] = int(t)
  7. for t in words.values():
  8.     point[t-1] += 1
  9. print(*point)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement