n = int(input())
d = {}

for i in range(n):
  s = str(input())
  if s in d.keys():
    d[s] += 1
  else:
    d[s] = 1

max_count = max(d.values())

for i in sorted(d.keys()):
  if d[i] == max_count:
    print(i) n = int(input()) n int(input()) int input() input d = {} d {} for i in range(n):
  s = str(input())
  if s in d.keys():
    d[s] += 1
  else:
    d[s] = 1 i range(n) range n s = str(input()) s str(input()) str input() input if s in d.keys():
    d[s] += 1
  else:
    d[s] = 1 s in d.keys() s d.keys() d.keys d keys d[s] += 1 d[s] d s 1 d[s] = 1 d[s] d s 1 max_count = max(d.values()) max_count max(d.values()) max d.values() d.values d values for i in sorted(d.keys()):
  if d[i] == max_count:
    print(i) i sorted(d.keys()) sorted d.keys() d.keys d keys if d[i] == max_count:
    print(i) d[i] == max_count d[i] d i max_count print(i) print i n = int(input()) int(input()) n d = {} {} d max_count = max(d.values()) max(d.values()) max_count s = str(input()) str(input()) s
n = int(input())
d = {}

for i in range(n):
  s = str(input())
  if s in d.keys():
    d[s] += 1
  else:
    d[s] = 1

max_count = max(d.values())

for i in sorted(d.keys()):
  if d[i] == max_count:
    print(i)