#5654. CSES1081 最大公约数
0
CSES1081 最大公约数
Common Divisors
You are given an array of n positive integers. Your task is to find two integers such that their greatest common divisor is as large as possible.
Input
The first input line has an integer n: the size of the array. The second line has n integers x_1,x_2,\ldots,x_n: the contents of the array.
Output
Print the maximum greatest common divisor.
Constraints
\cdot 10^5$
Example
Input
5
3 14 15 7 9
Output
7