N = int(raw_input()) eyes = [] for i in range(0, 999): eyes.append(0) for i in range(0, N): s = raw_input() eyes[len(s)-2] += 1 max = 0 tmp = -1 for i in range(0, 999): if max <= eyes[i]: tmp = i max = eyes[i] print tmp