PROGRAMMING:Java - find the number of times in the integer sequence
It is required to count the highest number of integers in an integer sequence and their occurrence times.
###Input format:
In a row, the number of integers n (0 < n ≤ 1000) in the sequence is given. N integers are given in turn, and each integer occupies one row.
###Output format:
In a row, output the integer with the highest number of occurrences and the number of occurrences, separated by spaces. The title guarantees that such a number is unique.
###Input example:
Here is a set of inputs. For example:
```in
ten
three
two
-1
five
three
four
three
0
three
two
```
###Output example:
The corresponding output is given here. For example:
```out
3 4
```
answer:If there is no answer, please comment
###Input format:
In a row, the number of integers n (0 < n ≤ 1000) in the sequence is given. N integers are given in turn, and each integer occupies one row.
###Output format:
In a row, output the integer with the highest number of occurrences and the number of occurrences, separated by spaces. The title guarantees that such a number is unique.
###Input example:
Here is a set of inputs. For example:
```in
ten
three
two
-1
five
three
four
three
0
three
two
```
###Output example:
The corresponding output is given here. For example:
```out
3 4
```
answer:If there is no answer, please comment