Polling

No attempts yetTime limit1sMemory limit256 MB

Problem

Midterm elections are here. Help your local election commission by counting the votes and reporting the winner. If more than one candidate ties for the most votes, print all of their names in alphabetical order.

Input

The first line holds the number of votes nn (1n10001 \le n \le 1000). Each of the next nn lines holds one vote, which is a candidate name. A name consists of capital letters only and is 1 to 20 letters long.

Output

Print the name of the candidate with the most votes. If several candidates tie for the most votes, print all of their names in alphabetical order, one per line. Print no spaces, and print no blank line between names.