You are viewing a single comment's thread. Return to all comments →
N = int(input()) d = {} for _ in range(N): w = input() if w in d: d[w] += 1 else: d[w] = 1 print(len(d)) print(*d.values())
Seems like cookies are disabled on this browser, please enable them to open this website
Word Order
You are viewing a single comment's thread. Return to all comments →