This year, teacher 김갑동 has become the homeroom teacher of class 1 in grade 6. He plans to appoint a temporary class president first, then hold an official election after the students become familiar with one another. He wants to appoint the student who, among the students in his class, has shared a class at least once during grades 1 through 5 with the greatest number of other students.
So teacher 김갑동 made a table showing which class each student belonged to in grades 1 through 5.
For example, consider the following table for $5$ students.
| Grade 1 | Grade 2 | Grade 3 | Grade 4 | Grade 5 | |
| Student 1 | $2$ | $3$ | $1$ | $7$ | $3$ |
| Student 2 | $4$ | $1$ | $9$ | $6$ | $8$ |
| Student 3 | $5$ | $5$ | $2$ | $4$ | $4$ |
| Student 4 | $6$ | $5$ | $2$ | $6$ | $7$ |
| Student 5 | $8$ | $4$ | $2$ | $2$ | $2$ |
In this example, student $4$ shared a class with student $3$ in grade 2, with students $3$ and $5$ in grade 3, and with student $2$ in grade 4. Thus, among the students in this class, the students who have shared a class with student $4$ at least once are students $2$, $3$ and $5$, a total of $3$ students. Student $4$ has the largest number of former classmates among all students in this example, so this student becomes the temporary class president.
Given the classes each student belonged to in grades 1 through 5, write a program to choose the temporary class president.
Input
The first line contains an integer giving the number of students in the class. The number of students is at least $3$ and at most $1000$.
Starting from the second line, one line per student, in order starting with student $1$, contains five integers separated by single spaces indicating their classes in grades 1 through 5. Every given integer is at least $1$ and at most $9$.
Output
On the first line, output the number of the student chosen as temporary class president. If several students can be chosen, output only the smallest number among them.
Examples
Input 1
5 2 3 1 7 3 4 1 9 6 8 5 5 2 4 4 6 5 2 6 7 8 4 2 2 2
Output 1
4