X=int(eval(input()))

if X==3 or X==5 or X==7:

  print('YES')

else:

  print('NO')
n=int(eval(input()))

if n==3 or n==5 or n==7:

  print('YES')

else:

  print('NO')
X = int(eval(input()))
if X == 3 or X == 5 or X == 7:
    print("YES")
else:
    print("NO")

n = int(eval(input()))
if n == 3 or n == 5 or n == 7:
    print("YES")
else:
    print("NO")

-X = int(eval(input())) -if X == 3 or X == 5 or X == 7: +n = int(eval(input())) +if n == 3 or n == 5 or n == 7: