14313 - Market Fruit Hunt   

Description

Jack's grandmother went to the market to buy fruit today. She saw that the fruits were special and happily put various fruits into her shopping bag as if she were crazy. Now she wants to know which fruit appears the most in her shopping bag. Can you help her figure it out?

 

Input

The input contains multiple lines, each line containing the name of a fruit.

Each fruit name consists of 1 to 10 letters and contains only lowercase English letters.

Output

Output the name of the fruit that appears the most in the shopping bag, along with the corresponding quantity. Separate the fruit name and quantity with a space.

If there are multiple fruits with the same maximum quantity, choose the fruit with the longest name.

Sample Input  Download

Sample Output  Download

Tags




Discuss