#include <bits/stdc++.h>
#define MAXN   1000001
using namespace std;

typedef long long ll;

int main(){
	ios::sync_with_stdio(false); cin.tie(0);
    int n;
    cin>>n;
    int ar[n];
    int gcd =0;
    int c=0;
    for(int i=0;i<n;i++){
        cin>>ar[i];
        if(ar[i]%2==0){
            c++;
        }
    }
    gcd = ar[0];
    for(int i=0;i<n;i++){
        gcd = __gcd(gcd,ar[i]);
    }


    if(c>=2 && gcd!=1)
        cout<<"not coprime"<<endl;
    else if(c < 2 && gcd!=1)
        cout<<"pairwise coprime"<<endl;
    else if(gcd==1)
        cout<<"setwise coprime"<<endl;
}
