#000106

MaxGCD

For given n integers, you have to find the pair that has the greatest GCD (greatest common divider).


Input the first line of the standard input will contain the number n, and the next n lines will contain the number, each being at most 1 000 000 000. n will be at most 1 000 and at least 2.

Output To the standard output, write the GCD of the pair that has the biggest GCD.


Input:
6
9
6
391
8
24
60

Output:
12


Input:
2
71
16899

Output:
1

Submit solution

Coming later

The grading service will be connected in a later migration step. You can inspect the task and your previous results now.