N = int(input())

S = []

import collections

for i in range (0, N):
	S.append(str(input()))

S = sorted(S)
cnt = collections.Counter()

for word in S:
	cnt[word] += 1
    
mostCommon = cnt.most_common()

D = mostCommon[0][1]
print(mostCommon[0][0])
for i in range(1, len(set(S))):
	if mostCommon[i][1] == D:
		print(mostCommon[i][0])
	else:
		exit() N = int(input()) N int(input()) int input() input S = [] S [] import collections collections for i in range (0, N):
	S.append(str(input())) i range (0, N) range 0 N S.append(str(input())) S.append S append str(input()) str input() input S = sorted(S) S sorted(S) sorted S cnt = collections.Counter() cnt collections.Counter() collections.Counter collections Counter for word in S:
	cnt[word] += 1
     word S cnt[word] += 1 cnt[word] cnt word 1 mostCommon = cnt.most_common() mostCommon cnt.most_common() cnt.most_common cnt most_common D = mostCommon[0][1] D mostCommon[0][1] [0] mostCommon 0 1 print(mostCommon[0][0]) print mostCommon[0][0] [0] mostCommon 0 0 for i in range(1, len(set(S))):
	if mostCommon[i][1] == D:
		print(mostCommon[i][0])
	else:
		exit() i range(1, len(set(S))) range 1 len(set(S)) len set(S) set S if mostCommon[i][1] == D:
		print(mostCommon[i][0])
	else:
		exit() mostCommon[i][1] == D mostCommon[i][1] [i] mostCommon i 1 D print(mostCommon[i][0]) print mostCommon[i][0] [i] mostCommon i 0 exit() exit cnt = collections.Counter() collections.Counter() cnt D = mostCommon[0][1] mostCommon[0][1] D S = sorted(S) sorted(S) S N = int(input()) int(input()) N mostCommon = cnt.most_common() cnt.most_common() mostCommon S = [] [] S
N = int(input())

S = []

import collections

for i in range (0, N):
	S.append(str(input()))

S = sorted(S)
cnt = collections.Counter()

for word in S:
	cnt[word] += 1
    
mostCommon = cnt.most_common()

D = mostCommon[0][1]
print(mostCommon[0][0])
for i in range(1, len(set(S))):
	if mostCommon[i][1] == D:
		print(mostCommon[i][0])
	else:
		exit()