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



Sample input:
10


Sample output:
Yes

Submission status: Accepted

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

if Flag == True:
  print('No')
else:
  print('Yes')

Submission status: Accepted

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

Submission status: Accepted

Solution code:
n = int(input())

ans = []
for i in range(1, 10):
	for j in range(1, 10):
		ans.append(i * j)
ans = list(set(ans))

if n in ans:
	print("Yes")
else:
	print("No")

Submission status: Accepted

Solution code:
a = int(input())
b = "No"
for i in range(1,10):
    if a%i == 0 and 1 <= a//i and 9 >= a//i:
        b = "Yes"
print(b)

Submission status: Accepted

Solution code:
class Abc81:
    def __init__(self):
        self.N = int(input())

    def resolve(self):
        for i in range(1,10):
            temp_ans = self.N/i
            if temp_ans  < 10 and temp_ans.is_integer():
                ans = 'Yes'
                break
            else:
                ans = 'No'
        print(ans)        
            

resolver = Abc81()
resolver.resolve()

Submission status: Accepted

Solution code:
n=int(input())
ans="No"
for i in range(1,10):
  for j in range(1,10):
    if i*j==n:
      ans="Yes"
print(ans)

Submission status: Accepted

Solution code:
n=int(input())
s=[0]*100
for i in range(1,10):
  for j in range(1,10):
    s[10*i+j]=i*j
p=81
for k in range(0,100):
  if s[k]==n:
    p=p-1
if p==81:
  print('No')
else:
  print('Yes')

Submission status: Accepted

Solution code:
num = int(input())
hantei = 0
for i in range(1,num+1):
  p = num/i
  if p.is_integer() == True:
    if len(str(i)) == 1 and len(str(int(p))) == 1:
      hantei+=1
      break
      
      
if hantei == 0:
  print("No")
else:
  print("Yes")

Submission status: Accepted

Solution code:
def main():
    N = int(input())
    #N = int(a)*int(b)
    a = [1,2,3,4,5,6,7,8,9]
    b = [1,2,3,4,5,6,7,8,9]
    for s in a:
        #print(s)
        for w in b:
        # print("s={},w={}".format(s,w))
            
            if N == s * w:
                print('Yes')
                return
    print('No')
               
        
if __name__ == "__main__":
    main()

Submission status: Accepted

Solution code:
N = int(input())

num_list = []

for i in range(9):
    for j in range(9):
        num_list.append((i+1)*(j+1))

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

Submission status: Accepted

Solution code:
n = int(input())

flg = 0

for i in range(10):
	for j in range(10):
		if i * j == n:
			flg = 1

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

Submission status: Accepted

Solution code:
print('Yes'if int(input())in[i*j for i in range(1,10)for j in range(1,10)]else'No')

Submission status: Accepted

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

Submission status: Accepted

Solution code:
n = int(input())
out = 0
for i in range(10):
  for j in range(10):
    if i*j == n:
      print('Yes')
      exit()
print('No')

Submission status: Accepted

Solution code:
N = int(input())
ans ="No"
for i in range(1,10):
 for j in range(1,10):
  if i*j == N:
   ans = "Yes"
print(ans)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
n=int(input())
lis=[i for i in range(1,10)]
for x in lis:
  if n%x==0 and n//x<10:
    print('Yes')
    exit()
print('No')

Submission status: Accepted

Solution code:
import sys
x = int(input())

for i in range(1,10):
  for j in range(1,10):
    if (i*j) == x:
      print("Yes")
      sys.exit(0)
      
print("No")

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
import itertools
n = int(input())
number_list = [1,2,3,4,5,6,7,8,9]
pattern_list = list(itertools.combinations_with_replacement(number_list,2))
kuku = []
for tup in pattern_list:
    kuku.append(tup[0]*tup[1])
if n in kuku:
    print("Yes")
else:
    print("No")

Submission status: Accepted

Solution code:
N=int(input())

y=[]
for i in range(1,10):
    for j in range(1,10):
        x=i*j
        y.append(x)

count=0
for z in y:
    if N==z:
        count+=1
    else:
        count=count
if count==0:
    print('No')
else:
    print('Yes')

Submission status: Accepted

Solution code:
N = int(input())
List = [1,2,3,4,5,6,7,8,9]
A = []
for i in List:
  for j in List:
    A.append(i*j)
    
if N in A:
  print('Yes')
else:
  print('No')

Submission status: Accepted

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

Submission status: Accepted

Solution code:


import sys
input = sys.stdin.readline
sys.setrecursionlimit(10 ** 7)

def no():
    print("No")
def yes():
    print("Yes")
    
n=int(input().rstrip())

for a in range(1,10):
    for b in range(1,10):
        #print(a,end=" ")
        #print(b)
        if(a*b==n):
            yes()
            sys.exit()
no()

Submission status: Accepted

Solution code:
# coding:utf-8
N = int(input())

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
N = int(input())
if N >=82:
    print("No")

elif (N % 9 == 0):
    print("Yes")
elif (N % 8 == 0) and (N <= 72):
    print("Yes")
elif (N % 7 == 0) and (N <= 63):
    print("Yes")
elif (N % 6 == 0) and (N <= 54):
    print("Yes")
elif (N % 5 == 0) and (N <= 45):
    print("Yes")
elif (N % 4 == 0) and (N <= 36):
    print("Yes")
elif (N % 3 == 0) and (N <= 27):
    print("Yes")
elif (N % 2 == 0) and (N <= 18):
    print("Yes")
elif N<= 9:
    print("Yes")
else:
    print("No")

Submission status: Accepted

Solution code:
n=int(input())
for i in range(1,10):
  for k in range(1,10):
    if i*k==n:
      print('Yes')
      exit(0)
    elif i*k>n:
      break
print('No')

Submission status: Accepted

Solution code:
def solve(N):
    for i in range(10):
        for j in range(10):
            if i*j == N:
                return "Yes"
    return "No"

N = int(input())
ans = solve(N)
print(ans)

Submission status: Accepted

Solution code:
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")

Submission status: Accepted

Solution code:
N = int(input())
for i in range(9):
  for j in range(9):
    seki = (i+1)*(j+1)
    if seki == N:
      print('Yes')
      break
  else:
    continue
  break
else:
  print('No')

Submission status: Accepted

Solution code:
#!/usr/bin/env python3
from collections import defaultdict, Counter
from itertools import product, groupby, count, permutations, combinations
from math import pi, sqrt
from collections import deque
from bisect import bisect, bisect_left, bisect_right
from string import ascii_lowercase
from functools import lru_cache
import sys
sys.setrecursionlimit(10000)
INF = float("inf")
YES, Yes, yes, NO, No, no = "YES", "Yes", "yes", "NO", "No", "no"
dy4, dx4 = [0, 1, 0, -1], [1, 0, -1, 0]
dy8, dx8 = [0, -1, 0, 1, 1, -1, -1, 1], [1, 0, -1, 0, 1, 1, -1, -1]


def inside(y, x, H, W):
    return 0 <= y < H and 0 <= x < W


def ceil(a, b):
    return (a + b - 1) // b


def sum_of_arithmetic_progression(s, d, n):
    return n * (2 * s + (n - 1) * d) // 2


def gcd(a, b):
    if b == 0:
        return a
    return gcd(b, a % b)


def lcm(a, b):
    g = gcd(a, b)
    return a / g * b


YES = "Yes"  # type: str
NO = "No"  # type: str

def solve():
    return


def main():
    N = int(input())
    for i in range(1, 10):
        for j in range(1, 10):
            if i * j == N:
                print(YES)
                return
    print(NO)


if __name__ == '__main__':
    main()

Submission status: Accepted

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

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

Submission status: Accepted

Solution code:
import sys

N=int(input().strip())

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

Submission status: Accepted

Solution code:
N = int(input())
ans = 0
for a in range(1,10):
    for b in range(1,10):
        if N == a*b:
            ans = 1
if (ans == 1):
    print("Yes")
else:
    print("No")

Submission status: Accepted

Solution code:
n = int(input())

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

Submission status: Accepted

Solution code:
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")

Submission status: Accepted

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

Submission status: Accepted

Solution code:
n = int(input())

revList = [9, 8, 7, 6, 5, 4, 3, 2, 1]
for i in revList:
  if n % i == 0:
    if n/i < 10:
      print("Yes")
      break
else:
  print("No")

Submission status: Accepted

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

Submission status: Accepted

Solution code:
N = int(input())
for i in range(1,10):
    for j in range(1, 10):
        if i * j == N:
            print("Yes")
            exit()
        else:
            continue
print("No")

Submission status: Accepted

Solution code:
N = int(input())

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

Submission status: Accepted

Solution code:
N = int(input())
ans = "No"
for i in range(1,10):
    for j in range(1,10):
      if i*j == N:
        ans = "Yes"
        break
    
print(ans)

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

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

print("No")

Submission status: Accepted

Solution code:
n=int(input())
for i in range(1,10):
    for j in range(1,10):
        if n==i*j:
            print("Yes")
            exit()
print("No")

Submission status: Accepted

Solution code:
import heapq

N = int(input())

answer = 'No'
for i in range(1,10):
    for j in range(1, 10):
        if i * j == N:
            answer = 'Yes'
            break
    if answer == 'Yes':
        break
print(answer)

Submission status: Accepted

Solution code:
n = int(input())

flag = 0
for i in range(9):
    for j in range(9):
        if n == (i + 1) * (j + 1):
            flag += 1

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

Submission status: Accepted

Solution code:

n = int(input())
ans = 'No'
for x in range(1,10):
	if n/x in [1,2,3,4,5,6,7,8,9]:
		ans = 'Yes'

print(ans)

Submission status: Accepted

Solution code:
n = int(input())
ans = 'No'
for i in range(1,10):
  if n / i in [1,2,3,4,5,6,7,8,9]:
    ans = 'Yes'
print(ans)

Submission status: Accepted

Solution code:
N = int(input())
flag = 0

for i in range(1,10):
  syo,amari = divmod(N,i)
  if amari == 0 and syo < 10:
    flag = 1

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

Submission status: Accepted

Solution code:
def func(a):
    for i in range(1, 10):
        for n in range(1, 10):
            if a == i * n:
                print("Yes")
                return
    print("No")


# for i in range(1, 101):
#     print("{0}:".format(i), end="")
i = int(input())
func(i)

Submission status: Accepted

Solution code:
n = int(input())
import sys
for i in range(1,10):
    if (n%i == 0) and (n/i < 10):
        print('Yes')
        sys.exit()
print('No')

Submission status: Accepted

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

Submission status: Accepted

Solution code:
if __name__ == '__main__':

	n = int(input())
	A = []

	for x in range(1,10):
		for y in range(x,10):
			if x * y not in A:
				A.append(x * y)

	if n in A:
		print("Yes")
	else:
		print("No")

Submission status: Accepted

Solution code:
n=int(input())
 
a=[]
for i in range(1,10):
	if n/i<10 and n%i==0:
		a.append("Yes")
 
if "Yes" in a:
  print("Yes")
else:
  print("No")

Submission status: Accepted

Solution code:
N = int(input())
kuku= [1, 2, 3, 4, 5, 6, 7, 8, 9]
c = 0

for a in kuku:
    for b in kuku:
        if a*b == N:
            c+=1
if c>=1:
    print('Yes')
else:
    print('No')

Submission status: Accepted

Solution code:
N=int(input())
l={i*j for i in range(10) for j in range(10)}
print('Yes' if N in l else 'No')

Submission status: Accepted

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

Submission status: Accepted

Solution code:
N = int(input())

c = 0
for i in range(1,10):
  for j in range(1,10):
    if i*j == N:
      c += 1
if c >= 1:
  print('Yes')
else:
  print('No')

Submission status: Accepted

Solution code:
N = int(input())
for i in range(1,10) :
    for j in range(1,10) :
        if i * j == N :
            print("Yes")
            exit()

else :
    print("No")

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
# 2019-11-19 19:43:48(JST)
import sys
# import collections
# import math
# from string import ascii_lowercase, ascii_uppercase, digits
# from bisect import bisect_left as bi_l, bisect_right as bi_r
# import itertools
# from functools import reduce
# import operator as op
# import re
# import heapq
# import array
# from scipy.misc import comb # (default: exact=False)
# import numpy as np 

table = set()
for i in range(1, 10):
    for j in range(i, 10):
        table.add(i * j)

def main():
    n = int(sys.stdin.readline().rstrip())
    
    print('Yes' if n in table else 'No')


if __name__ == "__main__":
    main()

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
# 整数の入力
a = int(input())

text="No"

for i in range(1,10):
    for j in range(1,10):
        if i*j == a:
            text ="Yes"

print(text)

Submission status: Accepted

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

print("No")

Submission status: Accepted

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

Submission status: Accepted

Solution code:
from itertools import product

N = int(input())

print("Yes" if N in map(lambda p: p[0] * p[1], product(range(1, 10), range(1, 10))) else "No")

Submission status: Accepted

Solution code:
N = int(input())
for a in range(1, 10):
    b = N // a
    if a * b == N and b in range(1, 10):
        print('Yes')
        break
else:
    print('No')

Submission status: Accepted

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

Submission status: Accepted

Solution code:
import sys
a=int(input())
for i in range(10):
  for j in range(10):
    if i*j==a:
      print("Yes")
      sys.exit(0)
print("No")

Submission status: Accepted

Solution code:
n = int(input())
ans = 'No'
for i in range(1,10):
    if n % i == 0 and n // i < 10:
        ans = 'Yes'
        break
print(ans)

Submission status: Accepted

Solution code:
x=int(input())
f=False
for i in range(10):
  for j in range(10):
    if i * j == x:
      f = True
print("Yes" if f else "No")

Submission status: Accepted

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

Submission status: Accepted

Solution code:

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

Submission status: Accepted

Solution code:
N = int(input())
for i in range(1,10):
    for i1 in range(1,10):
        if (i*i1) == N:
            print("Yes")
            exit()
print("No")

Submission status: Accepted

Solution code:
N = int(input())
if N == 1:
    print('Yes')
else:
    ans = 'No'
    for i in range(1, min(N//2+1, 10)):
        if N % i == 0:
            n = N // i
            if n < 10:
                ans = 'Yes'
                break
    print(ans)

Submission status: Accepted

Solution code:
n = int(input())
num_list = [2,3,4,5,6,7,8,9]
div_flag = False
for num in num_list:
    if n / num < 10 and int(n/num)==n/num:
        div_flag = True
if div_flag or (n==1):
    print('Yes')
else:
    print('No')

Submission status: Accepted

Solution code:
n = int(input())
answer = 'No'

for x in range(1, 10):
  for y in range(1, 10):
    if n == x * y:
      answer = 'Yes'
      
print(answer)

Submission status: Accepted

Solution code:
import sys


def solve():
    readline = sys.stdin.buffer.readline
    mod = 10 ** 9 + 7
    n = int(readline())
    for i in range(1, 10):
        for j in range(1, 10):
            if i * j == n:
                print("Yes")
                exit()
    print("No")


if __name__ == '__main__':
    solve()

Submission status: Accepted

Solution code:
#2
ans = int(input())
ans_lists=[]
a = [1,2,3,4,5,6,7,8,9]
b = [1,2,3,4,5,6,7,8,9]
for a_youso in a:
    for b_youso in b:
        n=a_youso*b_youso
        ans_lists.append(n)
if ans in ans_lists:
    print('Yes')
else:
    print('No')

Submission status: Accepted

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

Submission status: Accepted

Solution code:
N = int(input())


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

print(state)

Submission status: Accepted

Solution code:
n=int(input())

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

Submission status: Accepted

Solution code:
A=input().split()
a=int(A[0])
p=0
for i in range(1,10):
    for j in range(1,10):
        if a==i*j and p==0:print("Yes");p=1
if p==0:print("No")

Submission status: Accepted

Solution code:
N = int(input())

if N in set([i * j for i in range(1, 10) for j in range (1, 10)]):
    print("Yes")
else:
    print("No")

Submission status: Accepted

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

Submission status: Accepted

Solution code:
import numpy as np

def judge(N):
  a = np.arange(1,10)
  b = np.reshape(a,(9,1))
  if N in a*b:
    print("Yes")
  else:
    print("No")

N = int(input())
judge(N)

Submission status: Accepted

Solution code:
N = int(input())
a = 0
for i in range(1, 10):
    if N % i == 0 and N/i<=9:
        a = 1

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

Submission status: Accepted

Solution code:
a=int(input())
if a<10:
  print('Yes')
else:
  f=False
  d=0
  for i in range(2,10):
    if a%i==0:
      f=True
      d=a//i
  if f==True and d<10:
    print('Yes')
  else:
    print('No')

Submission status: Accepted

Solution code:
print('Yes' if int(input()) in {i*j for i in range(10) for j in range(10)} else 'No')

Submission status: Accepted

Solution code:
N=int(input())
a=0
for i in range (2,10):
  if N%i==0:
    if N/i<=9:
      a=a+1
if (a==0 and N>1):
  print("No")
else:
    print("Yes")

Submission status: Accepted

Solution code:
n = int(input())
a = []
for i in range(9):
    for j in range(9):
        a.append((i+1)*(j+1))
b = True
if n in a:
    print("Yes")
else:
    print("No")

Submission status: Accepted

Solution code:
n = int(input())
def aaa():
    for a in range(1,10):
        for b in range(1,10):
            if n == a * b:
                return 'ok'
m = aaa()

if m == 'ok':
    print('Yes')
else:
    print('No')

Submission status: Accepted

Solution code:
N = int(input())

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

Submission status: Accepted

Solution code:
import sys
input= sys.stdin.readline

N = int(input())

li = [1,2,3,4,5,6,7,8,9]
ans = []
for i in range(len(li)):
    p = N % li[i]
    q = N // li[i]
    if (p==0):
        ans.append(q)

ansflag = False
if (len(ans)!=0):
    for i in ans:
        if (i in li):
            ansflag = True
            break
        else:
            continue

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
n, = map(int, raw_input().split())
found = False
for i in range(1,10):
    if n % i == 0 and n//i < 10:
        found = True

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

Submission status: Accepted

Solution code:
def main():
    table = [i * j for i in range(1, 9 + 1) for j in range(1, 9 + 1)]

    n = int(input())

    if n in table:
        print('Yes')
    else:
        print('No')


if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
num = int(input())
result = 'No'
for i in range(1,10):
  ans, odd = divmod(num,i)
  if not odd and ans<10:
    result = 'Yes'

print(result)

Submission status: Accepted

Solution code:

class Solution:
    def solve(self, n: int) -> str:

        prods = set()

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

        if n in prods:
            return 'Yes'
        else:
            return 'No'


if __name__ == '__main__':

    # standard input
    n = int(input())

    # solve
    solution = Solution()
    print(solution.solve(n))

Submission status: Accepted

Solution code:
N = int(input())
flg = 0

for i in range(1, 10, 1):
  if flg==1:
    break
  for j in range(1, 10, 1):
    if i*j==N:
      print("Yes")
      flg= 1
      break
    
      
if flg==0:
  print("No")

Submission status: Accepted

Solution code:
count=0
N=input()
N=int(N)

for a in range(1,9+1):
    for b in range(1,9+1):
        if N==a*b:
            count=count+1
        else:
            pass

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

Submission status: Accepted

Solution code:
import math
N=int(input())
n=int(math.sqrt(N))
a=0
b=0
if n<10:
  for i in range(1,n+1):
    if N%i==0:
      a=i
      b=N//i
      if b<10:
        print('Yes')
        exit()
else:
  for i in range(1,10):
    if N%i==0:
      a=i
      b=N//i
      if b<10:
        print('Yes')
        exit()
print('No')

Submission status: Accepted

Solution code:
import sys
N = int(input())
a = 1
b = 1
if (N == 1)or(N == 81):
    print("Yes")
elif (2 <= N <= 80):
    for a in range(1,10):
        for b in range(1,10):
            if N == a*b:
                print("Yes")
                sys.exit()
            else:
                None
    print("No")
    sys.exit()
elif 82 <= N:
    print("No")

Submission status: Accepted

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

Submission status: Accepted

Solution code:
n = int(input())

nums=[]

for i in range(1,10):
  for j in range(i,10):
    nums.append(i*j)

if n in nums:
  print('Yes')
else:
  print('No')

Submission status: Accepted

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

Submission status: Accepted

Solution code:
N = int(input())

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

print('No')

Submission status: Accepted

Solution code:
print(['No','Yes'][input()in{str(x*y)for x in range(1,10)for y in range(1,10)}])

Submission status: Accepted

Solution code:
n =int(input())
cnt = 0
for i in range(9):
    for j in range(9):
        if (i+1)*(j+1)==n:
            cnt+=1

if cnt!=0:
    print("Yes")
else:
    print('No')

Submission status: Accepted

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

Submission status: Accepted

Solution code:
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 == 1:
    print("Yes")
else:
    print("No")

Submission status: Accepted

Solution code:
lst = []
for i in range(1,10):
  for j in range(1,10):
    lst.append(i*j)

N = int(input())
if N in lst:
  print("Yes")
else:
  print("No")

Submission status: Accepted

Solution code:
N = int(input())

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

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

else:
    print("No")

Submission status: Accepted

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

Submission status: Accepted

Solution code:
#!/usr/bin/python3
# coding: utf-8

# 整数 > 整数型
def I(): return int(input())

# 整数列 '1 2 3 4' > 整数型リスト
def IsIl(): return list(map(lambda x: int(x), input().split()))

# 改行挟む整数列　'1/n 2/n 3/n' > 整数型りすと
def InIl(n): return [input() for i in range(n)]

# 整数列 '1 2' > 整数型タプル
def IsIt(): return map(lambda x: int(x), input().split())

# 改行挟む整数列　'1\n 2\n 3\n' > 整数型たぷる
def InIl(n): return map(input() for i in range(n))

# 文字列 'abcd' > 文字型リスト
def SsSl(): return list(map(lambda x: x, input()))

# 整数 '1234' > 整数型リスト

# 文字列 'aba' > 辞書（文字型:個数）{'a':2,'b':1}
def SSd():
    from collections import defaultdict
    A = input() # [int(i) for i in input().split()]
    dd=defaultdict(int)
    for a in A:
        dd[a]+=1
    return dd

n=I()

lis = []

for i in range(9):
    for j in range(9):
        lis.append((i+1)*(j+1))

if n in lis:
    print('Yes')
else:
    print('No')

Submission status: Accepted

Solution code:
N = int(input())

ans = "No"
for A in range(1, 10):
  for B in range(1, 10):
    if A * B == N:
      ans = "Yes"

print(ans)

Submission status: Accepted

Solution code:
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
import sys

input = sys.stdin.readline
n = int(input())

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

print("No")

Submission status: Accepted

Solution code:
a = int(input())

for i in range(1,10):
  for j in range(1,10):
    if a==i*j:
      print('Yes')
      exit()
print('No')

Submission status: Accepted

Solution code:
N = int(input())

flg=False

for i in range(1, 10):
    if N%i==0:
        if N/i in [1,2,3,4,5,6,7,8,9]:
            flg = True
if flg:
    print('Yes')
else:
    print('No')

Submission status: Accepted

Solution code:
n = int(input())
for i in range(1, min(10, n + 1)):
  if n % i == 0 and n // i < 10:
    print("Yes")
    break
else:
  print("No")

Submission status: Accepted

Solution code:
n = int(input())

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

Submission status: Accepted

Solution code:
# https://atcoder.jp/contests/abc144/tasks/abc144_b
# -*- coding: utf-8 -*-

input_val = int(input())
hantei = 0

for i in range(1, 10):
    val_side = input_val / i
    if val_side < 10 and i * int(val_side) == input_val:
        hantei = 1
        break

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

Submission status: Accepted

Solution code:
a = float(input())

l = [1,2,3,4,5,6,7,8,9]

for num in l:
    ret = a / num
    if ret.is_integer() and ret >= 1 and ret <= 9:
        print("Yes")
        exit(0)

print("No")

Submission status: Accepted

Solution code:
n = int(input())
for a in range(1,10):
  for b in range(1,10):
    if a * b == n:
      print("Yes")
      exit()
print("No")

Submission status: Accepted

Solution code:
n = int(input())
cnt = 0
for i in range(10):
    for j in range(10):
        if n == i*j:
            cnt = 1
            break
    if cnt:
        break
if cnt:
    print("Yes")
else:
    print("No")

Submission status: Accepted

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