D. The Seals of Shanghai
time limit per test
2 seconds
memory limit per test
256 megabytes
input
standard input
output
standard output

After his last mission, Lian, the spy, returns to Shanghai. In an ancient stone chest, he finds a sequence of numbers that protect an ancestral secret: the Seals of Shanghai.

To unlock the seals, Lian must follow a precise ritual. Initially, he chooses a fixed integer $$$M$$$ such that $$$1 \lt M \leq 10^9$$$. Then, he must perform a sequence of magical rounds. In each round, he chooses an integer $$$x$$$ with which he unlocks all the seals whose number $$$A_i$$$ satisfies $$$A_i \bmod M = x$$$.

Each round requires concentration and energy. Therefore, Lian wants to minimize the number of rounds to unlock all the seals. Additionally, he wants to know how many distinct values of $$$M$$$ allow him to achieve this minimum number of rounds.

Input

The first line contains an integer $$$N$$$ ($$$1 \leq N \leq 10^5$$$), the number of seals.

The second line contains $$$N$$$ integers $$$A_1, A_2, \dots, A_N$$$ ($$$1 \leq A_i \leq 10^9$$$), representing the numbers of the seals.

Output

Print two integers: the minimum number of rounds required to unlock all the seals and the number of distinct values of $$$M$$$ with which it is possible to achieve this minimum number of rounds.

Examples
Input
5
13 23 33 53 103
Output
1 3
Input
2
2 4
Output
1 1