N=int(input())

ls={}
max_ch=0
for i in range(N):
    ch=input()
    if not ch in ls:
        ls[ch]=1
    else:
        ls[ch]+=1
    if max_ch<ls[ch]:
        max_ch=ls[ch]

S=[]
for j in ls:
    if max_ch==ls[j]:
        S.append(j)

S=sorted(S)

for i in S:
    print(i) N=int(input()) N int(input()) int input() input ls={} ls {} max_ch=0 max_ch 0 for i in range(N):
    ch=input()
    if not ch in ls:
        ls[ch]=1
    else:
        ls[ch]+=1
    if max_ch<ls[ch]:
        max_ch=ls[ch] i range(N) range N ch=input() ch input() input if not ch in ls:
        ls[ch]=1
    else:
        ls[ch]+=1
     not ch in ls ch in ls ch ls ls[ch]=1 ls[ch] ls ch 1 ls[ch]+=1 ls[ch] ls ch 1 if max_ch<ls[ch]:
        max_ch=ls[ch] max_ch<ls[ch] max_ch ls[ch] ls ch max_ch=ls[ch] max_ch ls[ch] ls ch S=[] S [] for j in ls:
    if max_ch==ls[j]:
        S.append(j) j ls if max_ch==ls[j]:
        S.append(j) max_ch==ls[j] max_ch ls[j] ls j S.append(j) S.append S append j S=sorted(S) S sorted(S) sorted S for i in S:
    print(i) i S print(i) print i ch=input() input() ch max_ch=0 0 max_ch N=int(input()) int(input()) N S=[] [] S S=sorted(S) sorted(S) S max_ch=ls[ch] ls[ch] max_ch ls={} {} ls
N=int(input())

ls={}
max_ch=0
for i in range(N):
    ch=input()
    if not ch in ls:
        ls[ch]=1
    else:
        ls[ch]+=1
    if max_ch<ls[ch]:
        max_ch=ls[ch]

S=[]
for j in ls:
    if max_ch==ls[j]:
        S.append(j)

S=sorted(S)

for i in S:
    print(i)