from collections import Counter

N = int(input())
S = [input() for _ in range(N)]

S = Counter(S).most_common()
l = []
for i in S:
  if i[1] == S[0][1]: l.append(i[0])

l = sorted(l)
for i in l:
  print(i) from collections import Counter N = int(input()) N int(input()) int input() input input() for _ in range(N) for _ in range(N) _ range(N) range N for _ in range(N) input() input S = [input() for _ in range(N)] S [input() for _ in range(N)] S = Counter(S).most_common() S Counter(S).most_common() (S).most_common (S) Counter S most_common l = [] l [] for i in S:
  if i[1] == S[0][1]: l.append(i[0]) i S if i[1] == S[0][1]: l.append(i[0 i[1] == S[0][1] i[1] i 1 S[0][1] [0] S 0 1 l = sorted(l) l sorted(l) sorted l for i in l:
  print(i) i l print(i) print i N = int(input()) int(input()) N S = [input() for _ in range(N)] [input() for _ in range(N)] S l = sorted(l) sorted(l) l l = [] [] l S = Counter(S).most_common() Counter(S).most_common() S
from collections import Counter

N = int(input())
S = [input() for _ in range(N)]

S = Counter(S).most_common()
l = []
for i in S:
  if i[1] == S[0][1]: l.append(i[0])

l = sorted(l)
for i in l:
  print(i)