#include <iostream>
#include <algorithm>
#include <string>
#include <vector>
#include <queue>
#include <map>
#include <set>
#include <stack>
#include <cstring>
#include <cmath>
 
#define FOR(i, a, b) for(int i = (a); i < (b); i++)
#define rep(i, n) for(int i = 0; i < (n); i++)
#define MP make_pair
#define X first
#define Y second
#define all(v) v.begin(), v.end()
#define rev(v) v.rbegin(), v.rend()

using namespace std;
 
typedef long long ll;
typedef vector<int> vi;
typedef pair<int, int> P;

const int INF = 1<<29;

int gcd(int m, int n){
	return (n==0?m:gcd(n, m%n));
}

int main(){
	int n, a, b;
	cin >> n >> a;
	rep(i, n-1){
		cin >> b;
		a = gcd(a, b);
	}

	vector<int> ans;
	FOR(i, 1, sqrt(1.*a)+1){
		if(a%i == 0){
			ans.push_back(i);
			ans.push_back(a/i);
		}
	}
	sort(all(ans));
	ans.erase(unique(all(ans)), ans.end());
	rep(i, ans.size()){
		cout << ans[i] << endl;
	}

    return 0;
}
#include <bits/stdc++.h>
#define FOR(i,a,b) for(int i=(a);i<(b);i++)
#define RFOR(i,a,b) for(int i=(b) - 1;i>=(a);i--)
#define REP(i,n) for(int i=0;i<(n);i++)
#define RREP(i,n) for(int i=n-1;i>=0;i--)

#define PB push_back
#define INF (1<<29)
#define ALL(a) (a).begin(),(a).end()
#define RALL(a) (a).rbegin(),(a).rend()
#define CLR(a) memset(a,0,sizeof(a))
const int dx[] = {-1,0,0,1},dy[] = {0,1,-1,0};

typedef long long int ll;

using namespace std;

int main(){
    int n,m,l;
    cin >> n;
    if(n == 2){
	cin >> n >> m;
	if(n < m) swap(n,m);
	FOR(i,1,n+1){
	    if(n % i == 0 && m % i == 0){
		printf("%d\n",i);
	    }
	}
    }else{
	cin >> n >> m >> l;
	if(n < m) swap(n,m);
	if(n < l) swap(n,l);
	FOR(i,1,n+1){
	    if(n % i == 0 && m % i == 0 && l % i == 0){
		printf("%d\n",i);
	    }
	}

    }
    return 0;
}