from collections import Counter

n = int(input())
xc = Counter()
for _ in range(n):
    xc[input()] += 1

mx = xc.most_common(1)[0][1]
ans = []
for k, v in xc.items():
    if v == mx:
        ans.append(k)
ans.sort()
print(*ans, sep="\n") from collections import Counter n = int(input()) n int(input()) int input() input xc = Counter() xc Counter() Counter for _ in range(n):
    xc[input()] += 1 _ range(n) range n xc[input()] += 1 xc[input()] xc input() input 1 mx = xc.most_common(1)[0][1] mx xc.most_common(1)[0][1] [0] xc.most_common(1) xc.most_common xc most_common 1 0 1 ans = [] ans [] for k, v in xc.items():
    if v == mx:
        ans.append(k) k v xc.items() xc.items xc items if v == mx:
        ans.append(k) v == mx v mx ans.append(k) ans.append ans append k ans.sort() ans.sort ans sort print(*ans, sep="\n") print *ans ans sep="\n" sep "\n" ans = [] [] ans mx = xc.most_common(1)[0][1] xc.most_common(1)[0][1] mx n = int(input()) int(input()) n xc = Counter() Counter() xc
from collections import Counter

n = int(input())
xc = Counter()
for _ in range(n):
    xc[input()] += 1

mx = xc.most_common(1)[0][1]
ans = []
for k, v in xc.items():
    if v == mx:
        ans.append(k)
ans.sort()
print(*ans, sep="\n")
