n = int(eval(input()))

t = 0



for i in range(9):

  for j in range(9):

    if n == (i + 1) * (j + 1):

      t += 1

      

if t == 0:

  print('No')

else:

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

for i in range(1, 10):

    if n % i == 0:

        if n / i <= 9:

            print("Yes")

            break

else:

    print("No")

n = int(eval(input()))
t = 0
for i in range(9):
    for j in range(9):
        if n == (i + 1) * (j + 1):
            t += 1
if t == 0:
    print("No")
else:
    print("Yes")

n = int(eval(input()))
for i in range(1, 10):
    if n % i == 0:
        if n / i <= 9:
            print("Yes")
            break
else:
    print("No")

-t = 0 -for i in range(9): -    for j in range(9): -        if n == (i + 1) * (j + 1): -            t += 1 -if t == 0: +for i in range(1, 10): +    if n % i == 0: +        if n / i <= 9: +            print("Yes") +            break +else: -else: -    print("Yes")