n=int(input())
d={}
l=[]
for i in range(n):
  s=input()
  if s not in d:
    d[s]=1
  else:
    d[s]=d[s]+1
k=max(d.values())
for i,j in d.items():
  if j==k:
    l.append(i)
l.sort()
for i in range(len(l)):
  print(l[i]) n=int(input()) n int(input()) int input() input d={} d {} l=[] l [] for i in range(n):
  s=input()
  if s not in d:
    d[s]=1
  else:
    d[s]=d[s]+1 i range(n) range n s=input() s input() input if s not in d:
    d[s]=1
  else:
    d[s]=d[s]+1 s not in d s d d[s]=1 d[s] d s 1 d[s]=d[s]+1 d[s] d s d[s]+1 d[s] d s 1 k=max(d.values()) k max(d.values()) max d.values() d.values d values for i,j in d.items():
  if j==k:
    l.append(i) i j d.items() d.items d items if j==k:
    l.append(i) j==k j k l.append(i) l.append l append i l.sort() l.sort l sort for i in range(len(l)):
  print(l[i]) i range(len(l)) range len(l) len l print(l[i]) print l[i] l i s=input() input() s k=max(d.values()) max(d.values()) k d={} {} d n=int(input()) int(input()) n l=[] [] l
n=int(input())
d={}
l=[]
for i in range(n):
  s=input()
  if s not in d:
    d[s]=1
  else:
    d[s]=d[s]+1
k=max(d.values())
for i,j in d.items():
  if j==k:
    l.append(i)
l.sort()
for i in range(len(l)):
  print(l[i])