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

#define ll long long int
#define All(a) (a).begin(),(a).end()
//a<bでないといけない
ll gcd(ll a,ll b){
  b%=a;
  if(b==0)return a;
  else gcd(b,a);
}
bool analyze(vector<int>& v,int x){
  if(x==1)return true;
  for (int i = 2;i*i<=x;i++){
    if(x%i==0){
      auto result=find(All(v),i);
      if(result!=v.end()) return false;
      else v.push_back(i);
    }
  }
  auto
}

void solve(){
  int n,m;
  
  scanf("%d",&n);
  vector<int> A(n);
  for(int i=0;i<n;i++){
    scanf("%d",&A[i]);
  }
  sort(All(A));

  int tmp=A[0];
  for (int i = 1; i < n; i++)
  {
    tmp=gcd(tmp,A[i]);
  }
  if(tmp>1){ 
    printf("not coprime\n");
    return;
  }
  vector<int> X={};
  for (int i = 0; i < n; i++){
    if(analyze(X,A[i]))continue;
    else goto setwise;
  }
  //printf("%d",(int)X.size());
  printf("pairwise coprime\n");
  return;

setwise:
  printf("setwise coprime\n");
  return;

}
int main(){
  
  // int q=3;
  // while(q--){
  //   solve();
  // }
  // solve();
  printf("setwise coprime\n");

  return 0;
}