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())
a=[]
for i in range(1,10):
    for j in range(1,i+1):
        a.append(i*j)
if n in a:
  print("Yes")
else:
  print("No")

Submission status: Accepted

Solution code:
N = int(input())
k = set([i*j for i in range(10) for j in range(10)])
print("Yes" if N in k else "No")

Submission status: Accepted

Solution code:
import sys
n=int(input())
for j in range(2):
    for i in range(1,10):
        if n%(10-i)==0:
            n=n/(10-i)
            break
if n==1:
    print('Yes')
else:
    print('No')

Submission status: Accepted

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

Submission status: Accepted

Solution code:
n=int(input())
b=False
for x in range(1,10):
    for y in range(1,10):
        if x*y==n:b=True
if b:print("Yes")
else:print("No")

Submission status: Accepted

Solution code:
n = int(input())

yes = False
for i in range(1, 10):
  if yes : break
  for j in range(1, 10):
    if i * j == n:
      yes = True
      break

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

Submission status: Accepted

Solution code:
import sys
input=sys.stdin.readline
n=int(input())
L=[]
for i in range(1,10):
    for j in range(1,10):
        L.append(i*j)
print("Yes" if n in L else "No")

Submission status: Accepted

Solution code:
n = int(input())

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

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

Submission status: Accepted

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

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 <= 9:
    ans = 'Yes'
    break
print(ans)

Submission status: Accepted

Solution code:
import math,string,itertools,fractions,heapq,collections,re,array,bisect,sys,random,time,copy,functools
from collections import deque

sys.setrecursionlimit(10**7)
inf = 10**20
mod = 10**9 + 7

DR = [1, -1, 0, 0]
DC = [0, 0, 1, -1]

def LI(): return [int(x) for x in sys.stdin.readline().split()]
def LI_(): return [int(x)-1 for x in sys.stdin.readline().split()]
def LF(): return [float(x) for x in sys.stdin.readline().split()]
def LS(): return sys.stdin.readline().split()
def I(): return int(sys.stdin.readline())
def F(): return float(sys.stdin.readline())
def S(): return input()
     
def main():
    N = I()
    for i in range(1, 10):
        a, b = i, N//i
        if N % i != 0:
            continue
        if b >= 10:
            continue
        print('Yes')
        return
    print('No')
    

main()

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a = int(input())
flg = False
for i in range(10):
    for j in range(10):
        if(i*j == a):
           flg = True

if(flg):
    print("Yes")
else:
    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 n == i * j:
			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:

import sys
row = sys.stdin.readline


def read_int(row):
    return int(row().rstrip())

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

Submission status: Accepted

Solution code:
n = int(input())
se = set(x*y for x in range(1,10) for y in range(1, 10))
print('Yes' if n in se else 'No')

Submission status: Accepted

Solution code:
N = int(input())
num = [1, 2, 3, 4, 5, 6, 7, 8, 9]
x = 0
for i in range(9):
  if N/(9-i) in num:
    x += 1
  else:
    x += 0
    
if x!= 0:
  print("Yes")
else:
  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'
print(ans)

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
n = int(input())
f=True
i=1
while(f and i<=9):
  g=n/i-int(n/i)==0
  if g and n/i<=9:
    f=False
  else:
    i+=1
print("Yes" if not f else "No")

Submission status: Accepted

Solution code:
n = int(input())


for i in reversed(range(1,10)):
    if n % int(i) == 0:
        a = i
        n = int(n/a)
        break

if len(str(a)) == 1 and len(str(n)) == 1:
    print('Yes')
else:
    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 <= 9:
    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")
            break
    else:
        continue
    break
else:
    print("No")

Submission status: Accepted

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

Submission status: Accepted

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

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

    print('No')
main()

Submission status: Accepted

Solution code:
# A,B = map(int, input().split())
N = int(input())

ans = 'No'
for x in range(1,10):
  for y in range(1,10):
    if N == x*y:
      ans = 'Yes'

print(ans)

Submission status: Accepted

Solution code:
import sys

def propare():
    def iterate_tokens():
        for line in sys.stdin:
            for word in line.split():
                yield word
    tokens = iterate_tokens()
    N = int(next(tokens))

    solve(N)

def solve(N: int):
    for i in range(1, 10):
        for j in range(1, 10):
            if i*j == N:
                print('Yes')
                return
    print('No')
    return

 
if __name__ == "__main__":
    propare()

Submission status: Accepted

Solution code:
N = int(input())
is_ok = False
for p in range(1, 10):
    for q in range(1, 10):
        if p * q == N:
            is_ok = True
            break
    if is_ok:
        break

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

Submission status: Accepted

Solution code:
N = int(input())


is_ok = False
for num in range(1, 10):
    if N % num == 0 and 1 <= N / num <= 9:
        is_ok = True
        break
if is_ok:
    print('Yes')
else:
    print('No')

Submission status: Accepted

Solution code:
n = int(input())

for i in range(1, 10):
  m = n / i
  if len(str(m)) == 3 and str(m)[1:3] == ".0":
    print("Yes")
    break
else:
  print("No")

Submission status: Accepted

Solution code:
N = int(input())
lt = list()
for i in range(1, 10):
    for j in range(1, 10):
        lt.append(i*j)
if N in lt:
    print('Yes')
else:
    print('No')

Submission status: Accepted

Solution code:
#!/usr/bin/env python3

n = int(input())
kuku = [i*j for i in range(10) for j in range(10)]
if n in kuku:
    print("Yes")
else:
    print("No")

Submission status: Accepted

Solution code:

n = int(input())
status = 0

for i in range(1,10):
    if n % i == 0:
        if 1 <= n / i <= 9:
            print("Yes")
            status = 1
            break

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

Submission status: Accepted

Solution code:
n = int(input())
 
List = [i * j for i in range(1, 10) for j in range(1, 10)]

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

Submission status: Accepted

Solution code:
def is_99(n):
    for i in range(1, 10):
        for j in range(1, 10):
            if i*j == n:
                return True
    return False


n = int(input())
if is_99(n):
    print('Yes')
else:
    print('No')

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
# 2020/01/23
# AtCoder Beginner Contest 144 - B

# Input
n = int(input())

ans = "No"
for i in range(1, 10):
    for j in range(1, 10):
        wk = i * j
        if wk == n:
            ans = "Yes"
            break

# Output
print(ans)

Submission status: Accepted

Solution code:
c=[]
for i in range(1,10):
  for j in range(1,10):
    c.append(i*j)
n=int(input())
if n in c:
  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 < 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) % 1 ) == 0 and 1 <= (N / i) <= 9:
    ans = "Yes"
    break

print(ans)

Submission status: Accepted

Solution code:
n=int(input())
for i in range(9):
    a,b=divmod(n,9-i)
    if a<=9 and b==0:
        print("Yes")
        break
else:
    print("No")

Submission status: Accepted

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

Submission status: Accepted

Solution code:
import itertools
N=int(input())
for i,j in itertools.product(range(1,10),repeat=2):
  if i*j==N:
    print('Yes')
    break
else:
   print('No')

Submission status: Accepted

Solution code:
n = int(input())

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

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
         break
if flag==1:
   print("Yes")
else:
   print("No")

Submission status: Accepted

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

Submission status: Accepted

Solution code:
n=int(input())
if n<10:
    print('Yes')
else:

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

Submission status: Accepted

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

if not_found:
    print("No")

Submission status: Accepted

Solution code:
n = int(input())
L = [q for q in range(1, 10)]
for i in L:
    if n % i == 0 and n // i in L:
        print("Yes")
        exit()
print("No")

Submission status: Accepted

Solution code:
n = int(input())

def getans(n):
    flag = False
    for i in range(1,10):
        if (n % i)  == 0 and n/i <= 9.0:
            flag = True
            return(flag)
    return(flag)

if getans(n):
    print('Yes')
else:
    print('No')

Submission status: Accepted

Solution code:
N = int(input())
box = [[i * j for i in range(1, 10)] for j in range(1, 10)]
for i in range(9):
    if N in box[i]:
        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(0)
print("No")

Submission status: Accepted

Solution code:
N = int(input())

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

print("Yes" if N in ls else "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(9,0,-1):
  tmp = n/i 
  if tmp > 9:
    print("No")
    exit(0)
  if tmp.is_integer():
    print("Yes")
    exit(0)

print("No")

Submission status: Accepted

Solution code:
N = int(input())

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

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

Submission status: Accepted

Solution code:
N = int(input())

for i in range(9):
    div = i+1
    ans = N//div
    
    if (N%div == 0 and ans <= 9):
        print('Yes')
        i = -1
        break
if (i != -1):
    print('No')

Submission status: Accepted

Solution code:
n = int(input())

possible = False
for x in range(1, 10):
    for y in range(1, 10):
        if x * y == n:
            possible = True
            break

if possible:
    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")
        break
else:
    print("No")

Submission status: Accepted

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

Submission status: Accepted

Solution code:
N = int(input())
cnt = 1
while cnt <= 9:
    if N%cnt == 0 and 1 <= N/cnt <= 9:
            print('Yes')
            break
    else:
        cnt += 1
else:
    print('No')

Submission status: Accepted

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

Submission status: Accepted

Solution code:
#B
N=int(input())
flag=0
for i in range(1,10):
    if (N/i).is_integer() and (N/i)<=9:
        flag=1
        #print(i)
    else:
        temp=0

        
if flag==1:
    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 i * j == N:
      print("Yes")
      exit()
print("No")

Submission status: Accepted

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

Submission status: Accepted

Solution code:

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

ABC144B()

Submission status: Accepted

Solution code:
n =int(input())
for i in range(1,10):
    t = False
    for k in range(1,10):
        if i*k==n:
            print('Yes')
            t=True
            break
    if t: break
else:
    print('No')

Submission status: Accepted

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

Submission status: Accepted

Solution code:
n = int(input())
mset = set([x*y for x in range(1,10) for y in range(1,10)])
print('Yes') if n in mset else print('No')

Submission status: Accepted

Solution code:
n=int(input());
k=[];
for i in range(1,10):
	for j in range(1,10):
		k.append(i*j);

print("Yes" if n in k else "No");

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a = int(input())

s = 0

for i in range(1, 10):
  for j in range(i, 10):
    s = i*j
    if s == a:
      break
    if s == 81:
      print("No")
  if s == a:
      print("Yes")
      break

Submission status: Accepted

Solution code:
N = int(input())
is_matched = False
res = ""

for i in range(1, 10):
    for j in range(1, 10):
        if N == i * j:
            is_matched = True
            res = "Yes"
            break
    if is_matched:
        break
    elif i == j == 9:
        res = "No"
print(res)

Submission status: Accepted

Solution code:
from itertools import product
N = int(input())
print("Yes" if N in {a*b for a,b in product(range(1, 10), range(1, 10))} else "No")

Submission status: Accepted

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

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
N = int(input())
L = [i*j for i in range(1,10) for j in range(1,10)]
if N in L:
  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')
      break
  else:
    continue
  break
else:
  print('No')

Submission status: Accepted

Solution code:
from itertools import product
print('Yes' if int(input()) in [i * j for i, j in product(range(1, 10), repeat=2)] else 'No')

Submission status: Accepted

Solution code:
N = int(input())
check = False
for i in range(1,10):
  if N%i==0 and N//i <=9 and N//i >=1:
    check = True
if(check):
  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 itertools
N = int(input())

if N > 81:
  print('No')
  exit()

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

Submission status: Accepted

Solution code:
import sys
 
N = int(input())
 
for x in range(1, 10):
    for y in range(1, 10):
        if(N==x*y):
            print("Yes")
            sys.exit()
 
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 i*j == N:
            count = 1
if count > 0:
    print('Yes')
else:
    print('No')

Submission status: Accepted

Solution code:
N = int(input())
ans = ''
if N > 81 or N < 1:
    ans = 'No'
else:
    a = [i for i in range(1,10)]
    for i in a:
        q, mod = divmod(N, i)
        if q < 10 and mod == 0:
            ans = 'Yes'
            break
if ans == 'No' or ans == '':
    print('No')
else:
    print('Yes')

Submission status: Accepted

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

Submission status: Accepted

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

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

    print('No')

if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
n = int(input())

res=set()
for i in range(1, 10):
  for j in range(1, 10):
    res.add(i * j)
if n in res:
  print("Yes")
else:
  print("No")

Submission status: Accepted

Solution code:
numbers = set()
for i in range(10):
  for j in range(10):
    numbers.add(i * j)

def solve():
  n = int(input())
  
  return 'Yes' if n in numbers else 'No'

print(solve())

Submission status: Accepted

Solution code:
N = int(input())

kuku = [i * j for i in range(1, 10) for j in range(1, 10)]

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

Submission status: Accepted

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

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

Submission status: Accepted

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

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

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

Submission status: Accepted

Solution code:
import itertools

def main():
    N = int(input())
    for i in range(10):
        for j in range(10):
            if N == (i*j):
                print("Yes")
                return 0
    print("No")
    return 0
if __name__ == '__main__':
    main()

Submission status: Accepted

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

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

if not flag:
    print('No')

Submission status: Accepted

Solution code:
a = int(input())
li = []

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

if a in li:
  print('Yes')
else:
  print('No')

Submission status: Accepted

Solution code:
input = int(input())

flag = False
for num in range(1, 10):
  q, mod = divmod(input, num)
  if(q <= 9 and mod == 0):
    flag = True
    break
    
if(flag):
  print('Yes')
else:
  print('No')

Submission status: Accepted

Solution code:

N = int(input())
A = 100000000000

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

else:
    print('No')

Submission status: Accepted

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

Submission status: Accepted

Solution code:
A = int(input())
flag = False
for i in range(1,10):
  if flag:
    break;
  for j in range(1,10):
    if i*j == A:
      flag = True
    else:
      flag = False
    if flag:
      break;
if flag:
  print('Yes')
else:
  print('No')

Submission status: Accepted

Solution code:
"""
author : halo2halo
date : 9, Jan, 2020
"""

import sys

read = sys.stdin.buffer.read
readline = sys.stdin.buffer.readline
readlines = sys.stdin.buffer.readlines
sys.setrecursionlimit(10 ** 7)

N = int(readline())

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

se = set(x * y for x in range(1, 10) for y in range(1, 10))

ans = 'Yes' if N in se else 'No'
print(ans)

Submission status: Accepted

Solution code:
"""
author : halo2halo
date : 9, Jan, 2020
"""

import sys

read = sys.stdin.buffer.read
readline = sys.stdin.buffer.readline
readlines = sys.stdin.buffer.readlines
sys.setrecursionlimit(10 ** 7)

N = int(readline())

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


ans = 'Yes' if flag else 'No'
print(ans)

Submission status: Accepted

Solution code:
X = int(input())
A = [1,2,3,4,5,6,7,8,9]
B = [1,2,3,4,5,6,7,8,9]
C =[]

for i in A:
    for j in B:
        k=i*j
        C.append(k)

C= list(set(C))

if X in C:
    print("Yes")
else:
    print("No")

Submission status: Accepted

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

if __name__ == "__main__":
    main()

Submission status: Accepted

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

def main():
    n = int(input())
    for i in range(1, 10):
        if n % i == 0:
            sho = n // i
            if 1 <= sho and sho <= 9:
                print("Yes")
                return 0
    print("No")

if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
import sys


def solve(inp):
    N = int(inp.readline().strip())

    for a in range(1, 10):
        for b in range(1, 10):
            if a * b == N:
                return "Yes"
    return "No"


def main():
    result = solve(sys.stdin)
    if result:
        print(result)


if __name__ == '__main__':
    main()

Submission status: Accepted

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

for i in range(1,10):
  if n % i == 0 and n/i < 10:	#1~9で割り切れて、かつ商が９以下
    print("Yes")
    sys.exit()

print("No")

Submission status: Accepted

Solution code:
n = int(input())

for i in range(1,10):
  if n % i == 0 and n/i < 10:	#1~9で割り切れて、かつ商が９以下
    print("Yes")
    break
  elif i==9:
    print("No")

Submission status: Accepted

Solution code:
n = int(input())
k = 0
for i in range(1, 10):
  for j in range(i, 10):
    seki = i * j
    if n == seki:
      k += 46
    else:
      k += -1
if k < 0:
  print("No")
else:
  print("Yes")

Submission status: Accepted

Solution code:
N = int(input())

ans = "No"
for i in range(9):
	if (N % (i+1) == 0) & ( N / (i+1) <= 9):
		ans = "Yes"
		break
print(ans)

Submission status: Accepted

Solution code:
N=int(input())

kuku = []

#全探索
for i in range(1,10,1):
  for j in range(1,10,1):
    kuku.append(i*j)
    
if N in kuku:
  print("Yes")
else:
  print("No")

Submission status: Accepted

Solution code:
N = int(input())

n_list = []
for x in range(1,10):
    for y in range(1,10):
        n_list += [x*y]

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

Submission status: Accepted

Solution code:
# encoding:utf-8
import copy
import random
import bisect #bisect_left　これで二部探索の大小検索が行える
import fractions #最小公倍数などはこっち
import math
import sys
import bisect

mod = 10**9+7
sys.setrecursionlimit(mod) # 再帰回数上限はでdefault1000

def LI(): return list(map(int, sys.stdin.readline().split()))

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

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

Submission status: Accepted

Solution code:
x=int(input())
for i in range(1,10):
    if(x%i==0 and x/i<10):
        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')
            break
    else:
        continue
    break
else:
    print('No')

Submission status: Accepted

Solution code:
n = int(input())

result = 'No'

for i in range(1, 10, 1):
    for j in range(1, 10, 1):
        if n == i * j:
            result = 'Yes'

print(result)

Submission status: Accepted

Solution code:
n = int(input())
flag = False

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

if not(flag):
    print("No")

Submission status: Accepted

Solution code:
import math,string,itertools,fractions,heapq,collections,re,array,bisect,sys,copy,functools
import time,random

sys.setrecursionlimit(10**7)
inf = 10**20
eps = 1.0 / 10**10
mod = 10**9+7
dd = [(-1,0),(0,1),(1,0),(0,-1)]
ddn = [(-1,0),(-1,1),(0,1),(1,1),(1,0),(1,-1),(0,-1),(-1,-1)]

def LI(): return list(map(int, sys.stdin.readline().split()))
def LLI(): return [list(map(int, l.split())) for l in sys.stdin.readlines()]
def LI_(): return [int(x)-1 for x in sys.stdin.readline().split()]
def LF(): return [float(x) for x in sys.stdin.readline().split()]
def LS(): return sys.stdin.readline().split()
def I(): return int(sys.stdin.readline())
def F(): return float(sys.stdin.readline())
def S(): return input()
def pf(s): return print(s, flush=True)
def pe(s): return print(str(s), file=sys.stderr)
def JA(a, sep): return sep.join(map(str, a))
def JAA(a, s, t): return s.join(t.join(map(str, b)) for b in a)


def main():
    n = I()
    for i in range(1,10):
        if n % i == 0 and n // i < 10:
            return "Yes"

    return "No"


print(main())

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
# coding: utf-8
# Your code here!

N = int(input())

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
N = int(input())
I = 0
J = 0
for i in range(9):
  for j in range(9):
    if (i + 1) * (j + 1) == N:
      I = i + 1
      J = j + 1
      break

print("Yes" if I*J >= 1 else "No")

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
import sys
n = int(input())
for x in range(1,10):
 for y in range(1,10):
  if x*y == n:
   print("Yes")
   sys.exit()

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(0)

print("No")