n=int(input())
A=list(map(int,input().split(" ")))
def gcd(a, b):
    while b:
        a, b = b, a % b
    return a

base=A[0]
condition=0
for i in range(1,len(A),1):
    g=gcd(base,A[i])
    base*=A[i]
    if g!=1:
        condition=2
        break
base=A[0]
if condition!=0:
    for i in range(1,len(A),1):
        base=gcd(base,A[i])
        if base==1:
            condition=1
            break
ans=["pairwise coprime","setwise coprime","not coprime"]
print(ans[condition])
