n=int(input())
dic=dict()
for i in range(n):
    s=input()
    if s in dic:
        dic[s]+=1
    else:
        dic[s]=1
ans=[]
val=max(dic.values())
for kv in dic.items():
    if kv[1]==val:
        ans.append(kv[0])
ans=sorted(ans)
for a in ans:
    print(a) n=int(input()) n int(input()) int input() input dic=dict() dic dict() dict for i in range(n):
    s=input()
    if s in dic:
        dic[s]+=1
    else:
        dic[s]=1 i range(n) range n s=input() s input() input if s in dic:
        dic[s]+=1
    else:
        dic[s]=1 s in dic s dic dic[s]+=1 dic[s] dic s 1 dic[s]=1 dic[s] dic s 1 ans=[] ans [] val=max(dic.values()) val max(dic.values()) max dic.values() dic.values dic values for kv in dic.items():
    if kv[1]==val:
        ans.append(kv[0]) kv dic.items() dic.items dic items if kv[1]==val:
        ans.append(kv[0]) kv[1]==val kv[1] kv 1 val ans.append(kv[0]) ans.append ans append kv[0] kv 0 ans=sorted(ans) ans sorted(ans) sorted ans for a in ans:
    print(a) a ans print(a) print a dic=dict() dict() dic ans=[] [] ans s=input() input() s n=int(input()) int(input()) n val=max(dic.values()) max(dic.values()) val ans=sorted(ans) sorted(ans) ans
n=int(input())
dic=dict()
for i in range(n):
    s=input()
    if s in dic:
        dic[s]+=1
    else:
        dic[s]=1
ans=[]
val=max(dic.values())
for kv in dic.items():
    if kv[1]==val:
        ans.append(kv[0])
ans=sorted(ans)
for a in ans:
    print(a)
