n = int(input())
a = list(map(int, input().split()))

import math
g = math.gcd(a[0], a[1])
for i in range(2, n):
    g = math.gcd(g, a[i])

print(g) n = int(input()) n int(input()) int input() input a = list(map(int, input().split())) a list(map(int, input().split())) list map(int, input().split()) map int input().split() ().split () input split import math math g = math.gcd(a[0], a[1]) g math.gcd(a[0], a[1]) math.gcd math gcd a[0] a 0 a[1] a 1 for i in range(2, n):
    g = math.gcd(g, a[i]) i range(2, n) range 2 n g = math.gcd(g, a[i]) g math.gcd(g, a[i]) math.gcd math gcd g a[i] a i print(g) print g g = math.gcd(g, a[i]) math.gcd(g, a[i]) g n = int(input()) int(input()) n g = math.gcd(a[0], a[1]) math.gcd(a[0], a[1]) g a = list(map(int, input().split())) list(map(int, input().split())) a
n = int(input())
a = list(map(int, input().split()))

import math
g = math.gcd(a[0], a[1])
for i in range(2, n):
    g = math.gcd(g, a[i])

print(g)