n positive integers are given. Find the greatest common divisor of these numbers.
The first line contains one integer n (n≤1000). The second line contains n positive integers, each does not exceed 2⋅109.
Print the greatest common divisor of given numbers.