import math
from functools import reduce


def main():
    N = int(input())
    A = list(map(int, input().split()))

    gcd_ = reduce(math.gcd, A)

    if gcd_ == 1:
        print('setwise coprime')
    else:
        print('pairwise coprime')


if __name__ == '__main__':
    main()
