A town census, was the birthday of all residents. Now you write a program to find the town's oldest and most young people.
Make sure that each date entered here are legitimate, but not necessarily reasonable - assuming there is no known town more than 200 years old, and today is September 6, 2014, the more than 200-year-old's birthday and not born birthday is unreasonable and should be filtered out.
Input formats:
In the first line of the input is given a positive integer N, the value (; then N rows, each individual is given a name (a string of not more than 5 letters of the English), and press yyyy/mm/dd
(i.e., year / month / day) birthday format given in the title to ensure the oldest and the youngest person not tied.
Output formats:
The number of valid order of the output birthday in a row, young people and most of the oldest names, separated by spaces between them.
Sample input:
5
John 2001/05/12
Tom 1814/09/06
Ann 2121/01/30
James 1814/09/05
Steve 1967/11/20
Sample output:
3 Tom John
achieve: