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

x = a[0]
for i in range(1,n):
    x,y = max(x,a[i]),min(x,a[i])
    while y!=0:x,y=y,x%y
print(x) 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 x = a[0] x a[0] a 0 for i in range(1,n):
    x,y = max(x,a[i]),min(x,a[i])
    while y!=0:x,y=y,x%y i range(1,n) range 1 n x,y = max(x,a[i]),min(x,a[i]) x max(x,a[i]) max x a[i] a i y min(x,a[i]) min x a[i] a i while y!=0:x,y=y y!=0 y 0 print(x) print x y = max(x,a[i]),min(x,a[i]) min(x,a[i]) y a = list(map(int,input().split())) list(map(int,input().split())) a x,y = max(x,a[i]),min(x,a[i]) max(x,a[i]) x n = int(input()) int(input()) n x = a[0] a[0] x
n = int(input())
a = list(map(int,input().split()))

x = a[0]
for i in range(1,n):
    x,y = max(x,a[i]),min(x,a[i])
    while y!=0:x,y=y,x%y
print(x)