Problem:
 Score : 200 points    Problem Statement Having learned the multiplication table, Takahashi can multiply two integers between 1 and 9 (inclusive) together.  Given an integer N , determine whether N can be represented as the product of two integers between 1 and 9 . If it can, print Yes ; if it cannot, print No .      Constraints  1 \leq N \leq 100  N is an integer.         Input Input is given from Standard Input in the following format:  N       Output If N can be represented as the product of two integers between 1 and 9 (inclusive), print Yes ; if it cannot, print No .        Sample Input 1 10      Sample Output 1 Yes  10 can be represented as, for example, 2 \times 5 .       Sample Input 2 50      Sample Output 2 No  50 cannot be represented as the product of two integers between 1 and 9 .       Sample Input 3 81      Sample Output 3 Yes

Solution (Python):
N=int(input())
co=0
for i in range(1,10):
    for j in range(1,10):
        if i*j==N:
            co+=1
if co>0:
    print("Yes")
else:
    print("No")

Solution (Python):
n = int(input())
ans = 'No'

for i in range(1, 10, 1):
  d = n // i
  if type(d) is int and d < 10 and n == d * i:
    ans = 'Yes'
    break
    
print(ans)

Solution (Python):


n = int(input())
ans = False

for i in range(1,10):
    for j in range(1,10):
        if (i*j == n):
            ans =True
            
if ans:
    print("Yes")
else:
    print("No")

Solution (Python):
N=int(input())

for i in reversed(range(1,10)):
    if N%i==0:
        if N/i > 9:
            print('No')
            exit(0)
        else:
            print('Yes')
            exit(0)

Solution (Python):
N = int(input())
DEBUG = False
flag = False
for i in range(1,10):
    div = int(N / i)
    if DEBUG:
        print('i = %d : div = %d'%(i,div))
    if i*div == N and div-9 <=0:
        flag = True
    if flag:
        break
        
if flag:
    print('Yes')
else:
    print('No')

Solution (Python):
import sys
sys.setrecursionlimit(int(1e6))

N = int(input())

a = 1
while (a <= 9):
    if ((N % a) == 0) and ((N // a) <=9):
        break
    a += 1

if a <= 9:
    print('Yes')
else:
    print('No')

Solution (Python):
import sys

INPUT = lambda: sys.stdin.readline().rstrip()
INT = lambda: int(INPUT())

sys.setrecursionlimit(10 ** 9)


def main():
    N = INT()

    num = [i for i in range(1, 10)]

    for i in num:
        if N % i == 0 and N//i in num:
            print("Yes")
            sys.exit()

    print("No")


if __name__ == '__main__':
    main()

Solution (Python):
N = int(input())

def make_divisors(n):
    divisors = []
    for i in range(1, int(n**0.5)+1):
        if n % i == 0:
            divisors.append(i)
            if i != n // i:
                divisors.append(n//i)

    return divisors

ans = make_divisors(N)
ans.sort()

while len(ans)>2:
    ans = ans[1:-1]
if len(ans)==1:
    if ans[0]<=9:
        print("Yes")
    else:
        print("No")
else:
    if ans[1]<=9:
        print("Yes")
    else:
        print("No")

Solution (Python):
n = int(input())
flag = 0

for i in range(1,10):
    for j in range(1,10):
        if i * j == n:
            flag += 1

if flag == 0:
    print('No')
else:
    print('Yes')

Solution (Python):
N = int(input())
x = [i for i in range(1,10)]
x.reverse()
flag=0
for i in x:
  if N%i==0 and N/i<10:
    print("Yes")
    flag = 1
    break
if flag==0:
  print("No")

Solution (Python):
def main():
    n = int(input())

    for i in range(1, 10):
        for j in range(1, 10):
            if n == i*j:
                return 'Yes'
    return 'No'
                
if __name__ == "__main__":
    print(main())

Solution (Python):
N=int(input())

for i in range(1,10):
    if N%i==0:
        if (N/i)//10>0:
            pass
        else:
            print('Yes')
            break
else:
    print('No')

Solution (Python):
N = int(input())
flag = 0
for i in range(1,10,1):
  if N % i == 0 and N/i < 10:
    print("Yes")
    flag = 1
    break
if flag == 0:
  print("No")

Solution (Python):
import sys

N=int(input())
if N>81:
    print("No")
    sys.exit()
for i in range(1,10):
    if N%i==0 and N/i<10:
        print("Yes")
        sys.exit()
print("No")

Solution (Python):
n = int(input())
s = 'No'
if (n > 81) or (n < 1):
    print(s)
elif n < 10:
    print('Yes')
else:
    for i in range(1,10):
        if (n % i == 0) & (n // i <= 9):
            s = 'Yes'
            break
    print(s)

Solution (Python):
n = int(input())

for i in range(9):
  if (n % (i+1)) == 0 and (n // (i+1)) < 10:
    print('Yes')
    exit()

print('No')

Solution (Python):
N = int(input())

res = []
for i in range(9):
    if N % (i+1) == 0 and N // (i +1) <= 9:
        res.append(1)
    else:
        res.append(0)

if max(res) == 0:
    print('No')
else:
    print('Yes')

Solution (Python):
n=int(input())
l=[]
for i in range(1,10):
    for j in range(1,10):
        l.append(i*j)
if n in l:
    print('Yes')
else:
    print('No')

Solution (Python):
N = int(input())
for i in range(1,10):
    if N % i == 0 and N // i < 10:
        print("Yes")
        exit()
print("No")

Solution (Python):
N = int(input())
if N<=10:
  print('Yes')
elif N ==12 or N == 14 or N == 15 or N == 16 or N == 18 or N ==21 or N == 24 or N == 27:
  print('Yes')
elif N ==20 or N == 32 or N == 36 or N == 35 or N ==40 or N == 45 or N == 25:
  print('Yes')
elif N ==42 or N == 48 or N == 54 or N == 49 or N ==56 or N == 63 or N == 64:
  print('Yes')
elif N == 72 or N == 81:
  print('Yes')
else:
  print('No')

Solution (Python):
Y = []

for i in range(1,10):
  for j in range(1,10):
    Y.append(i*j)
    
N = int(input())

if N in Y:
  print('Yes')
else:
  print('No')

Solution (Python):
x=int(input())
for i in range(1,10):
  if x%i==0:
    if x/i<10:
      print('Yes');exit()
      
print('No')

Solution (Python):
n = int(input())
for i in range(1,10):
    for j in range(1,10):
        if n == i*j:
            print('Yes')
            exit(0)

print('No')

Solution (Python):
import math
N = int(input())
limit = math.sqrt(N)


for i in range(1,10):
        if N % i == 0:
                if len(str(int(N / i))) < 2:
                        print("Yes")
                        exit()
print("No")

Solution (Python):
N = int(input())
for i in range(1, 10):
    if N % i == 0:
        s = N/i
        if s < 10:
            print("Yes")
            exit()

print("No")

Solution (Python):
n = int(input())
hoge = ''
for i in range(9):
  for j in range(9):
    if (i+1)*(j+1) == n:
      hoge = 'Yes'
      break
if hoge != 'Yes':
  hoge = 'No'
print(hoge)

Solution (Python):
N = int(input())

for i in range(1, 10):
    for j in range(1, 10):
        if N == i*j:
            flag = True
            break
        else:
            flag = False
    if flag:
        break

if flag:
    print('Yes')
else:
    print('No')

Solution (Python):
n = int(input())

for i in range(1, 10):
  amari = n % i
  if amari == 0:
    if n / i < 10:
      print("Yes")
      exit()
print("No")

Solution (Python):
N = int(input())

ans = 0
for i in range(1, 10):
    a = N % i 
    b = N // i
    if  a == 0 and b < 10:
        ans = 1

if ans == 1:
    print("Yes")
else:
    print("No")

Solution (Python):
n = int(input())
count = []
for i in range(1,10):
    if n%i == 0:
        a = n//i
        count.append(a)

ans = 0
for j in range(len(count)):
    if count[j] <= 9:
        ans += 1

if ans == 0:
    print("No")
else:  
    print("Yes")

Solution (Python):
n=int(input())
l=[9,8,7,6,5,4,3,2,1]
a=0
for i in l:
    a=n/i
    if a.is_integer():
        break
print("Yes" if a<10 else "No")

Solution (Python):
import math
n = int(input())
if n == 0:
  print('No')
  exit()
elif n == 1:
  print('Yes')
  exit()
for k in range(2, 10):
  if n % k == 0 and n / k <= 9:
    print('Yes')
    exit()
print('No')

Solution (Python):
n=int(input())
kuku=[]
for i in range(1,10):
    for j in range(1,10):
        kuku.append(i*j)
ans='No'
for k in range(0,81):
    if n!=kuku[k]:
        pass
    else:
        ans='Yes'
        break
print(ans)

Solution (Python):
N = int(input())
A = {i*j for i in range(1, 10) for j in range(1, 10)}
if N in A:
    print('Yes')
else:
    print('No')

Solution (Python):

N = int(input())

for x in range(1, 10):
    if N/x in range(1,10):
        print('Yes')
        break
else:
    print('No')

Solution (Python):
n = int(input())

for i in range(10):
    for j in range(10):
        if i * j == n:
            print('Yes')
            exit()

print("No")

Solution (Python):
import sys
n = int(input())

for i in range(1, 10):
    a = n//i
    if a < 10:
        if i*a == n:
            print("Yes")
            sys.exit()
    else:
        continue

print("No")

Solution (Python):
n=int(input())
l=[]
for i in range(1,10):
  for j in range(1,10):
    l.append(i*j)
if n in l:
  print('Yes')
else:
  print('No')

Solution (Python):
def a(n):
    for wi in range(9):
        for hi in range(9):
            if n == ((wi+1) * (hi+1)):
                return "Yes";
            else:
                continue;
n = int(input());

if a(n) == "Yes":
    print("Yes");
else:
    print("No");

Solution (Python):
n = int(input())
list=[]
for i in range(1,10):
     for j in range(1,10):
         list.append(i*j)
if n in list:
    print("Yes")
else:
    print("No")

Solution (Python):
x = int(input())
for i in range(1, 10):
    if x % i == 0 and 0 < x / i and x / i < 10:
        print("Yes")
        break
    elif i == 9:
        print("No")

Solution (Python):
N=int(input())
a=0
num=[1,2,3,4,5,6,7,8,9]
for i in num:
    for j in num:
        if N==i*j:
            a+=1
if a>=1:
    print('Yes')
else:
    print('No')

Solution (Python):
n = int(input())

num = [ i*j for i in range(1,10) for j in range(1,10) ]
print( "Yes" if n in num else "No" )

Solution (Python):
import sys
n = int(input())
ans = "No"
if n > 81:
  print("No")
else:
  for i in range(1,10):
    for j in range(1,10):
      if i * j == n:
        ans = "Yes"
  print(ans)

Solution (Python):
A = int(input())
def calc(A):
  for i in range(1, 10):
    for j in range(1, 10):
      if i*j == A:
        return 'Yes'
  return 'No'
print(calc(A))

Solution (Python):
N = int(input())
list = [1, 2, 3, 4, 5, 6, 7, 8, 9]
ans = 0
if N <= 81:
    for i in range(9):
        if N%int(list[i]) == 0 and N/int(list[i]) in list:
            ans += 1
        else:
            ans = ans
    if ans != 0:
        print('Yes')
    else:
        print('No')
else:
    print('No')

Solution (Python):
N = int(input())

kuku = set([])

for i in range(1,10):
    for j in range(1,10):
        kuku.add(i*j)

if N in kuku:
    print("Yes")
else:
    print("No")

Solution (Python):
n = int(input())
for a in range(10):
  for b in range(10):
    if a*b==n:
      print('Yes')
      exit()
print('No')

Solution (Python):

N = int(input())

ans = {}

for a in range(1, 10):
    for b in range(1,10):
        ans[str(a * b)] = True


try:
    t = ans[str(N)]
    print("Yes")
except KeyError:
    
    print("No")

Solution (Python):
N = int(input())
if N==1 or N==2 or N==3 or N==4 or N==5 or N==6 or N==7 or N==8 or N==9 or N==4 or N==6 or N==8 or N==10 or N==12 or N==14 or N==16 or N==18 or N==9 or N==12 or N==15 or N==18 or N==21 or N==24 or N==27 or N==16 or N==20 or N==24 or N==28 or N==32 or N==36 or N==25 or N==30 or N==35 or N==40 or N==45 or N==36 or N==42 or N==48 or N==54 or N==49 or N==56 or N==63 or N==64 or N==72 or N==81:
    print('Yes')
else:
    print('No')

Solution (Python):
import sys
N = int(input())
for i in range(1, 10):
  if N / i == int(N / i):
    if N / i < 10:
      print("Yes")
      sys.exit()
print("No")

Solution (Python):
n = int(input())
flag=False
for i in range(1,10):
    for j in range(1,10):
        if(n == i*j):
            flag=True
            break


print("Yes" if flag else "No")

Solution (Python):

import sys
read = sys.stdin.readline


def read_ints():
    return list(map(int, read().split()))


def read_a_int():
    return int(read())


def read_matrix(H):
    '''
    H is number of rows
    '''
    return [list(map(int, read().split())) for _ in range(H)]


def read_map(H):
    '''
    H is number of rows
    文字列で与えられた盤面を読み取る用
    '''
    return [read()[:-1] for _ in range(H)]


def read_col(H, n_cols):
    '''
    H is number of rows
    n_cols is number of cols

    A列、B列が与えられるようなとき
    '''
    ret = [[] for _ in range(n_cols)]
    for _ in range(H):
        tmp = list(map(int, read().split()))
        for col in range(n_cols):
            ret[col].append(tmp[col])

    return ret


N = read_a_int()
tmp = []
for i in range(1, 10):
    for j in range(1, 10):
        tmp.append(i*j)

if N in tmp:
    print('Yes')
else:
    print('No')

Solution (Python):
N=int(input())
counter=0
for i in range(1,10):
    if N/i==1 or N/i==2 or N/i==3 or N/i==4 or N/i==5 or N/i==6 or N/i==7 or N/i==8 or N/i==9:
        print('Yes')
        break
    else:
        counter+=1
if counter==9:
    print('No')

Solution (Python):
N = int(input())

flag = 0
for i in range(1,10):
    if N % i == 0:
        if N / i < 10:
            flag = 1
            break

if flag == 1:
    print("Yes")
else:
    print("No")

Solution (Python):


N = int(input())

if N == 0:
    print('No')
elif N > 81:
    print('No')
else:
    for i in range(1, 10):
        
        if N % i == 0 and N // i < 10:
            print('Yes')
            break
    else:
        print('No')

Solution (Python):
import sys
n = int(input())

for a in range(9):
  
  if(n % (a+1) == 0):
    if(n/(a+1) < 10):
      print("Yes")
      sys.exit()
print("No")

Solution (Python):
N=int(input())


cond=0
if N>81:
  print('No')
elif N<10:
  print('Yes')
else: 
  for j in range(2,10):
    if N%j ==0 and N//j <=9:
      print('Yes')
      cond=1
      break
  if cond==0:
    print('No')

Solution (Python):
import sys
N = int(input())
for i in range(1,10):
  for j in range(1,10):
    if i*j == N:
      print("Yes")
      sys.exit()
print("No")

Solution (Python):
n = int(input())
l = list(range(1, 10))
f = False

for i in l:
	if (n/i) in l: 
		f = True
		print('Yes')
		break
if f == False:
	print('No')

Solution (Python):
num = int(input())

num_range = range(1, 10)

flag = False

for n in reversed(num_range):
    if flag:
        break
    if num % n == 0:
        temp = num / n
        for m in num_range:
            if flag:
                break
            if temp == m:
                flag = True

if flag:
    print("Yes")
else:
    print("No")

Solution (Python):
N = int(input())

A = {1, 2, 3, 4, 5, 6, 7, 8, 9}
flag = 0

for i in A:
	for j in A:
		if N == i*j:
			flag = 1

if flag == 0:
	print("No")
else:
	print("Yes")

Solution (Python):
N = int(input())

for i in range(1, 10):
    q, mod = divmod(N, i)
    if mod == 0 and q <= 9:
        print("Yes")
        q = 0
        break

if q != 0:
    print("No")

Solution (Python):
num = int(input())
flag=0
for i in range(1,10):
    if num % i == 0 and num/i < 10:
        flag=1

if flag==1:
    print("Yes")
else:
    print("No")

Solution (Python):
n=int(input())
flag=False
for i in range(9,0,-1):
	if n%i==0:
		x=n//i 
		y=i 
		if x>=1 and x<=9 and y>=1 and y<=9:
			flag=True
if flag:
	print("Yes")
else:
	print("No")

Solution (Python):
N = int(input())

res = 'No'

for i in range(1,10):
    if (N % i == 0) & (N // i < 10):
        res = 'Yes'

print(res)

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

Solution (Python):
N = int(input())

for i in reversed(range(1,10)):
  if N % i == 0 and N / i <= 9:

    print('Yes')
    exit()

print('No')

Solution (Python):
a = int(input())
for num in range(1,10):
  if a / num == a//num and 1 <= a//num <=9:
    print('Yes')
    break
else:
  print('No')

Solution (Python):
N = int(input())
x = [1,2,3,4,5,6,7,8,9]
t = [1,2,3,4,5,6,7,8,9]
c = "No"
for y in range(len(x)):
  for z in range(len(t)):
    if N == (x[y]*t[z]):
      c = "Yes"
      break
print(c)

Solution (Python):
n = int(input())
for i in range(1, 10):
    if not n%i and n/i <= 9:
        print('Yes')
        exit()
print('No')

Solution (Python):




import sys
sys.setrecursionlimit(10**6)
readline = sys.stdin.readline 

from itertools import accumulate

n = int(input())



for i in range(1,10):
    for j in range(1,10):
        if i*j == n:
            print("Yes")
            exit()

print("No")

Solution (Python):
N = int(input())
hantei = 0
for i in range(9, 0, -1):
    for k in range(9, 0, -1):
        if N / (i*k) == 1:
            hantei += 1
print('Yes' if hantei >= 1 else 'No')

Solution (Python):
n = int(input())
l = []
i = 1
while i < 10:
    j = 1
    while j < 10:
        l.append(i * j)
        j += 1
    i += 1
if n in l:
    print('Yes')
else:
    print('No')

Solution (Python):
def main():
  N = int(input())
  for i in range(10):
    for j in range(10):
      if i*j == N:
        print("Yes")
        return
  print("No")

main()

Solution (Python):
N=int(input())
for i in range(9):
  if N%(i+1)==0 and N/(i+1)<=9 :
    print("Yes")
    break
else :
  print("No")

Solution (Python):


def main():
    n = int(input())
    r = range(1,10)

    for i in r:
        if((n/i) in r):
            print("Yes")
            exit(0)

    print("No")
main()

Solution (Python):


n = int( input() )

flag = False
for i in range(1, 10):
    if( n % i == 0 and int(n/i) in range(10) ):
        print("Yes")
        flag = True
        break
if not flag:       
    print("No")

Solution (Python):
import sys
N = int(input())
nums = [1,2,3,4,5,6,7,8,9]
for n in nums:
  if N/n in nums:
    print('Yes')
    sys.exit()
print('No')

Solution (Python):
A = int(input())
if A % 9 == 0 and len(str(A//9)) == 1:
    print("Yes");exit()
elif A % 8 == 0 and len(str(A//8)) == 1:
    print("Yes");exit()
elif A % 7 == 0 and len(str(A//7)) == 1:
    print("Yes");exit()
elif A % 6 == 0 and len(str(A//6)) == 1:
    print("Yes");exit()
elif A % 5 == 0 and len(str(A//5)) == 1:
    print("Yes");exit()
elif A % 4 == 0 and len(str(A//4)) == 1:
    print("Yes");exit()
elif A % 3 == 0 and len(str(A//3)) == 1:
    print("Yes");exit()
elif A % 2 == 0 and len(str(A//2)) == 1:
    print("Yes");exit()
elif A % 1 == 0 and len(str(A//1)) == 1:
    print("Yes");exit()
else:
    print("No")

Solution (Python):
n = int(input())

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

print(ans)

Solution (Python):
N = int(input())
multi_list = []
for i in range(1, 10):
  for j in range(1, 10):
    multi_list.append(i*j)
 
if N in multi_list:
  print('Yes')
else:
  print('No')

Solution (Python):
a = int(input())
c = 0

for i in range(1,10):
  j = 10-i
  if a%j == 0:
    a = a/j
    c += 1
  if c == 2:
    break
  if a%j == 0:
    a = a/j
    c += 1
  if c == 2:
    break
if a == 1 and c <= 2:
  print('Yes')
else:
  print('No')

Solution (Python):
def main():

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

if __name__ == "__main__":
    main()

Solution (Python):
N = int(input())
def make_divisors(n):
    divisors = []
    for i in range(1, int(n**0.5)+1):
        if n % i == 0:
            divisors.append(i)
            if i != n // i:
                divisors.append(n//i)
    return divisors

arr = sorted(make_divisors(N))

if len(arr)%2==0:
  if arr[len(arr)//2-1]>=10 or arr[len(arr)//2]>=10:
    print('No')
  else:
    print('Yes')
else:
  if arr[len(arr)//2]>=10:
    print('No')
  else:
    print('Yes')

Solution (Python):
n = int(input())
count = 0
for i in range(1, 10):
    for j in range(1, 10):
        if n == i*j:
            count += 1
        else:
            count += 0
if count == 0:
    print("No")
else:
    print("Yes")

Solution (Python):
N = int(input())

result = 'No'
for i in range(1, 10):
  if N % i == 0 and N // i < 10:
    result = 'Yes'
    break
    
print(result)

Solution (Python):
N=int(input())
A=list(range(1,10))
i=0
while i<2:
    for a in reversed(A):
        if N%a==0:
            N=N//a
            i+=1
            break
if N==1:
    print("Yes")
else:
    print("No")

Solution (Python):
a = int(input())
for i in range(0, 9):
    if a%(9-i)==0:
        a/=(9-i)
        break
if(1<=a and a<=9):
    print("Yes")
else:
    print("No")

Solution (Python):
if __name__ == "__main__":
    N = int(input())
    if N == 1:
        print("Yes")
        exit()
    for i in range(1, min(N, 10)):
        n1 = N % i
        n2 = N // i
        if n1 == 0 and n2 < 10:
            print("Yes")
            exit()

    print("No")

Solution (Python):
n1 = int(input())

r1 = "No"

for i1 in range(9):
    if n1 % (i1 + 1) == 0:
        if n1 // (i1 + 1) < 10:
            r1 = "Yes"

print(r1)

Solution (Python):
N = int(input())
if N < 1 or 81 < N:
    print("No")
else:
    result = "No"
    for i in range(1, 10):
        if i * 10 <= N:
            continue
        if N % i == 0:
            result = "Yes"
            break
    print(result)

Solution (Python):
n=int(input())

ans=str("No")
for i in range(1, 10):
    w=n//i
    l=len(str(w))
    if l == 1:
        if w*i==n:
            ans=str("Yes")
            break

print(ans)

Solution (Python):
a = int(input())
for val in range(9):
    if a%(val+1)==0 and a/(val+1) <=9:
        print("Yes")
        exit()
print("No")

Solution (Python):
n = int(input())
test = [1, 2, 3, 4, 5, 6, 7, 8, 9]

ans = 'No'
for i in test:
    if n % i == 0:
        if int(n/i) <= 9:
            ans = 'Yes'
            break
    else:
        ans = 'No'

print(ans)

Solution (Python):
A = int(input())

count = 0

for i in range(1,10):
    if A % i == 0:
        if A / i < 10:
        	count += 1
if count == 0:
    print('No')
else:
    print('Yes')

Solution (Python):
N = int(input())
c=0
for i in range(1,10):
  if N % i == 0:
    if 1<=N/i<=9:
      c=c+1
if c==0:
  print('No')
else:
  print('Yes')

Solution (Python):
n = int(input())

ans = "No"
for i in range(1, 10):
    t = n/i
    if t.is_integer() and 1 == len(str(int(t))):
        ans = "Yes"
        break
print(ans)

Solution (Python):
N = int(input())


for i in range(1,10):
    A = N/i
    if N % i == 0 and A<10:
        print("Yes")
        exit()
print("No")

Solution (Python):
N = int(raw_input())
found = False
for i in range(1, 10):
    d, r = N/i, N%i
    if r == 0 and d < 10:
        found = True
        break

if found:
    print("Yes")
else:
    print("No")

Solution (Python):
N = int(input())
for i in range(1,10):
    if (N % i == 0) and ( N/i <= 9):
        print("Yes")
        exit()
print("No")

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

Solution (Python):
N = int(input())
L=set()
for i in range(1,10):
  for j in range(1,10):
    L.add(i*j)
if N in L:
  print("Yes")
else:
  print("No")

Solution (Python):
n = int(input())
out = "No"

for i in range(1,n):
  if n%i == 0:
    m = n//i
    if m < 10 and i < 10:
      out = "Yes"
      break

if n == 1:
  out = "Yes"
print(out)

Solution (Python):
N = int(input())
lst = sum([[x*y for y in range(x,10)] for x in range(1, 10)], [])
print('Yes' if N in lst else 'No')

Solution (Python):
import sys
import itertools
input = sys.stdin.readline

_n = int(input())


def chker(n):
    for i in range(1, 10):
        if n % i == 0:
            m = n // i
            if 0 < m and m < 10:
                print('Yes')
                return

    print('No')


chker(_n)

Solution (Python):
N = int(input())

for i in range(1,10):
	if N%i == 0:
		if N/i < 10:
			print("Yes")
			exit()

print("No")

Solution (Python):
N = int(input())
flag = False
for i in range(1,10):
    if N % i == 0:
        if N / i < 10:
            flag = True

if flag:
    print('Yes')
else:
    print('No')

Solution (Python):
n = int(input())

for x in range(1, 10):
    for y in range(1, 10):
        if(n == x*y):
            print("Yes")
            exit()
print("No")

Solution (Python):
import sys
from collections import Counter, deque, defaultdict
from math import factorial
import heapq, bisect
import math
import itertools
sys.setrecursionlimit(10 ** 5 + 10)
INF = 10**15 +5
def input(): return sys.stdin.readline().strip()
def INT(): return int(input())
def MAP(): return map(int, input().split())
def LIST(): return list(map(int, input().split()))

n = INT()
res = 0
for i in range(9, 1, -1):
    if n%i == 0:
        res = n//i
        break
if n == 1:
    print('Yes')
elif res == 0:
    print('No')
elif res >= 10:
    print('No')
else:
    print('Yes')

Solution (Python):
import sys
def input():
    return sys.stdin.readline()[:-1]

n = int(input())

if n > 81:
    print('No')
    sys.exit()


for i in range(1, 10):
    for j in range(1, 10):
        if n == i * j:
            print('Yes')
            sys.exit()

print('No')

Solution (Python):
N = int(input())
aaa = 0 
box = []
for i in range(1, 10):
    if N % i == 0:
        box.append(int(N/i))
for k in box:
    if k>=1 and k<=9:
        aaa = 1 
        break
    else:
        aaa = 0 
if aaa == 1:
    print("Yes")
else:
    print("No")

Solution (Python):
A = int(input())

for i in range(9):
  if A % (i+1) == 0 and A / (i+1) <= 9:
    print("Yes")
    break
  elif i == 8:
    print("No")
    break

Solution (Python):
N = int(input())
s = 'No'
for i in range(1,10):
    for j in range(1, 10):
        if i * j == N:
            s = 'Yes'

print(s)

Solution (Python):
N = int(input())
D = 0
C = "No"
for i in range(9):
	D = N%(i+1)
	if D==0:
		if N//(i+1)<=9:
			C = "Yes"
			break
print(C)

Solution (Python):
N=int(input())

int_list = [1, 2, 3, 4, 5, 6, 7, 8, 9]
 
for A in int_list:
    if N % A == 0:
        B = N // A
        if B > 0 and B <= 9:
            print('Yes')
            exit()
print('No')

Solution (Python):
N = int(input())

if(N%1==0 and N//1<=9) or (N%2==0 and N//2<=9) or (N%3==0 and N//3<=9) or (N%4==0 and N//4<=9) or (N%5==0 and N//5<=9) or (N%6==0 and N//6<=9) or (N%7==0 and N//7<=9) or (N%8==0 and N//8<=9) or (N%9==0 and N//9<=9):
  print("Yes")
else:
  print("No")

Solution (Python):
N = int(input())

jug = False

for i in range(1, 10):
    if jug == True:
        break
    for j in range(1, 10):
        if i * j == N:
            print("Yes")
            jug =True
            break

if jug == False:
    print("No")

Solution (Python):
def fact(n):
    tmp = n
    ret = []
    while(True):
        if tmp == 1:
            break
        for i in range(2, n + 1):
            if tmp % i == 0:
                tmp = tmp / i
                ret.append(i)
                break
    return ret

n = int(input())

lis = fact(n)

bina = [0 for i in range(len(lis))]
ret = False
for i in range(2 ** len(lis)):

    A = 1
    B = 1
    for j in range(len(bina)):
        if bina[j] == 0:
            A *= lis[j]
        else:
            B *= lis[j]
    
    
    if A < 10 and B < 10:
        ret = True
        break

    bina[-1] += 1
    for j in range(len(bina) - 1, 0, -1):
        if bina[j] > 1:
            bina[j - 1] += 1
            bina[j] -= 2

if ret:
    print('Yes')
else:
    print('No')

Solution (Python):
n = int(input())
for i in range(2,10):
  if n % i == 0:
    if n / i <  10:
      print("Yes")
      exit()
if n == 1:
  print("Yes")
  exit()
print("No")

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

Solution (Python):
import sys

n = int(input())
qq = 0

for i in range(9):
    for j in range(9):
        if (i + 1) * (j + 1) == n:
            print("Yes")
            qq = (i + 1) * (j + 1)
            sys.exit()

if qq == 0:
    print("No")

Solution (Python):
n = int(input())
a = 0
for i in range(9):
    if n % (9-i) == 0:
        if n // (9-i) > 0 and n // (9-i) < 10:
            print('Yes')
            a = 1
            break
if a == 0:
    print('No')

Solution (Python):
n = int(input())

ans = 0

for i in range(1, 10):
    if n % i == 0:
        if n / i <= 9:
            ans += 1
    else:
        pass
    
if ans >= 1:
    print('Yes')
else:
    print('No')

Solution (Python):
import sys

N = int(input())

for i in range(9):
  for j in range(9):
    if N == (i + 1) * (j + 1):
      print('Yes')
      sys.exit()
print('No')

Solution (Python):
a = []
for i in range(1,10):
    for j in range(1,10):
        a.append(i*j)
b = int(input())
if b in a:
    print("Yes")
else:
    print("No")

Solution (Python):
import sys

N = int(input())

if N == 1:
    print('Yes')
    sys.exit()

for i in range(2,10):
    n = N/i
    if n < 10 and n.is_integer():
        print('Yes')
        sys.exit()
print('No')

Solution (Python):
a=int(input())	
flag=1

for i in range(1,10):

    if a%i==0 and a/i <=9:
        print("Yes")
        flag=-1
        break;
            

if flag==1:
    print("No")

Solution (Python):
n = int(input())
su = [1, 2, 3, 4, 5, 6, 7, 8, 9]
kuku = []
for i in su:
  for k in su:
    kuku.append(i * k)
if n in kuku:
  print("Yes")
else:
  print("No")

Solution (Python):
n = int(input())

ans = "No"
l = [1,2,3,4,5,6,7,8,9]
for i in range(1,10):
  if n/i in l:
    ans = "Yes"
    break
print(ans)

Solution (Python):
n = int(input())

flag = False
for i in range(1, 11):
  m = n // i
  r = n % i
  if r == 0 and m < 10 and i < 10:
    print ('Yes')
    flag = True
    break;

if flag == False:
  print ('No')

Solution (Python):
N = int(input())

if N < 10:
    print("Yes")
    exit()
for i in range(2,10):
    if N % i == 0:
        if N // i < 10:
            print("Yes")
            exit()
print("No")

Solution (Python):
N = int(input())

l = [i for i in range(1, int(N**0.5) + 1) if N % i == 0]
n = N / l[-1]
if n < 10 and l[-1] < 10:
  print("Yes")
else:
  print("No")

Solution (Python):
n=int(input())
a=[]
for i in range(1,10):
  for j in range(i,10):
    a.append(i*j)
print('Yes' if (n in a) else 'No')

Solution (Python):
import sys
input = sys.stdin.readline

def Main(n):
    ans = False
    for i in range(1, 10):
        if(n % i == 0):
            nn = n // i
            if(nn >= 10):
                ans = False
                continue
            if(n % nn == 0):
                ans = True
                break
    return 'Yes' if ans else 'No'
        

def main():
    N = int(input())
    print(Main(N))

if __name__ == '__main__':
    main()

Solution (Python):
import numpy as np

n = int(input())
answer = [[i * j for j in range(1, 10)] for i in range(1, 10)]

flag = 0
for ans in answer:
  for a in ans:
    if a == n:
        flag=1
        break

if flag == 1:
    print('Yes')
else:
    print('No')

Solution (Python):
n = int(input())
count = 0
for i in range(1, 10):
  if n%i == 0 and n//i <= 9:
    print('Yes')
    count += 1
    break

if count == 0:
  print('No')

Solution (Python):
N = str(input())

l = []
a = 0
b = 0

for i in range(9):
    for j in range(9):
        l.append(str((i+1)*(j+1)))
e = N in l

if e:
    print("Yes")
else:
    print("No")

Solution (Python):
N = int(input())
s = set()
for i in range(1,10):
    for j in range(1,10):
        s.add(i*j)
if N in s:
    print('Yes')
else:
    print('No')