def is_prime(N):
    if N < 2:
        return False
    i = 2
    while i*i <= N:
        if N % i == 0:
            return False
        i += 1
    return True


def main():
    N = int(input())
    if not is_prime(N):
        dsum = 0
        for c in str(N):
            dsum += int(c)
        if N == 1 or N % 10 in [2, 4, 5, 6, 8, 0] or dsum % 3 == 0:
            print("Not Prime")
            return
    print("Prime")


if __name__ == "__main__":
    main()
