Problem:


Score : 100 points

Problem Statement

Having learned the multiplication table, Takahashi can multiply two integers between 1 and 9 (inclusive) together. He cannot do any other calculation.

Given are two integers A and B.

If Takahashi can calculate A \times B, print the result; if he cannot, print -1 instead.

Constraints

1 \leq A \leq 20

1 \leq B \leq 20

All values in input are integers.

Input

Input is given from Standard Input in the following format:

A B

Output

If Takahashi can calculate A \times B, print the result; if he cannot, print -1.

Sample Input 1

2 5

Sample Output 1

10

2 \times 5 = 10.

Sample Input 2

5 10

Sample Output 2

-1

5\times 10 = 50, but Takahashi cannot do this calculation, so print -1 instead.

Sample Input 3

9 9

Sample Output 3

81



Sample input:
2 5


Sample output:
10

Submission status: Accepted

Solution code:
A, B = map(int, input().split())
if A <= 9 and B <= 9: print(A * B)
else: print(-1)

Submission status: Accepted

Solution code:
a, b = [int(i) for i in input().split()]
if 0 < a < 10 and 0 < b < 10:
    print(a * b)
else:
    print(-1)

Submission status: Accepted

Solution code:
a,b=map(int,input().split())

if a>=10 or b>=10:
    print(-1)
else:
    print(a*b)

Submission status: Accepted

Solution code:
#!/usr/bin/env python3
import sys
INF = float("inf")


def solve(A: int, B: int):
    if (1 <= A <= 9) and (1 <= B <= 9):
        print(A*B)
    else:
        print(-1)
    return


def main():

    def iterate_tokens():
        for line in sys.stdin:
            for word in line.split():
                yield word
    tokens = iterate_tokens()
    A = int(next(tokens))  # type: int
    B = int(next(tokens))  # type: int
    solve(A, B)


if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
import sys
sys.setrecursionlimit(2147483647)
INF=float("inf")
MOD=10**9+7
# input=lambda :sys.stdin.readline().rstrip()
def resolve():
    a,b=map(int,input().split())
    if(a>9 or b>9):
        print(-1)
    else:
        print(a*b)
resolve()

Submission status: Accepted

Solution code:
from collections import Counter,defaultdict,deque
import sys,bisect,math,itertools,string,queue
from heapq import heappop, heappush
sys.setrecursionlimit(10**8)
mod = 10**9+7
def inp(): return int(sys.stdin.readline())
def inpl(): return list(map(int, sys.stdin.readline().split()))
def inpl_str(): return list(sys.stdin.readline().split())
def inpln(n): return list(int(sys.stdin.readline()) for i in range(n))

a,b = inpl()
if a < 10 and b < 10:
    print(a*b)
else:
    print(-1)

Submission status: Accepted

Solution code:
a,b=map(int,input().split())
if a<=9 and b<=9:
  print(a*b)
else:print(-1)

Submission status: Accepted

Solution code:
A,B = map(int,input().split())
if A>9 or B>9:
    print(-1)
else:
    print(A*B)

Submission status: Accepted

Solution code:
A, B = list(map(int, input().split()))
if 1 <= A <= 9 and 1 <= B <= 9:
    print(A*B)
else:
    print(-1)

Submission status: Accepted

Solution code:
a, b = map(int, input().split())

if a>9 or b>9: print(-1)
else: print(a*b)

Submission status: Accepted

Solution code:
a, b= map(int,input().split())
if a < 10 and b < 10:
    print(a*b)
else:
    print(-1)

Submission status: Accepted

Solution code:
x,y = map(int,input().split())
if x <= 9 and y <= 9:
    print(x * y)
else:
    print(-1)

Submission status: Accepted

Solution code:

A,B = map(int,input().split())
if (A>=10 or B>=10):
    print(-1)
else:
    print(A*B)

Submission status: Accepted

Solution code:
x,y = map(int,input().split())
if 1<=x<=9 and 1<=y<=9:
    print(x*y)
else:
    print(-1)

Submission status: Accepted

Solution code:
import sys
from heapq import heappop, heappush
from operator import itemgetter
from collections import deque, defaultdict, Counter
from bisect import bisect_left, bisect_right
input = sys.stdin.readline
sys.setrecursionlimit(10 ** 7)
MOD = 10**9 + 7
INF = float('inf')

def sol():
    A, B = map(int, input().split())
    if 1 <= A <= 9 and 1 <= B <= 9:
        print(A * B)
    else:
        print(-1)


sol()

Submission status: Accepted

Solution code:
a,b=map(int,input().split())
if a>9 or b>9:
    print(-1)
else:
    print(a*b)

Submission status: Accepted

Solution code:
a, b = map(int, input().split())
if a<=9 and b<=9:
  print(a*b)
else:
  print(-1)

Submission status: Accepted

Solution code:
a,b=map(int,input().split())
if (1<=a<=9) and (1<=b<=9):
  print(a*b)
else:print(-1)

Submission status: Accepted

Solution code:
from copy import deepcopy
from sys import exit,setrecursionlimit
import math
from collections import defaultdict,Counter,deque
from fractions import Fraction as frac
import bisect
import sys
input = sys.stdin.readline

setrecursionlimit(1000000)

dp = defaultdict(lambda x:-1)

def main():
	a,b = map(int,input().split())
	if(a<10 and b<10):
		print(a*b)
	else:
		print(-1)

def zip(a):
	mae = a[0]
	ziparray = [mae]
	for i in range(1,len(a)):
		if(mae != a[i]):
			ziparray.append(a[i])
			mae = a[i]
	return ziparray

def is_prime(n):
	if n < 2: return False

	for k in range(2, int(math.sqrt(n)) + 1):
		if n % k == 0:
			return False

	return True

def list_replace(n,f,t):
	return [t if i==f else i for i in n]

def base_10_to_n(X, n):
	X_dumy = X
	out = ''
	while X_dumy>0:
		out = str(X_dumy%n)+out
		X_dumy = int(X_dumy/n)
	if(out == ''): return '0'
	return out

def gcd(l):
	x = l.pop()
	y = l.pop()
	while(x%y!=0):
		z = x%y
		x = y
		y = z
	l.append(min(x,y))
	return gcd(l) if len(l) > 1 else l[0]

class Queue():
	def __init__(self):
		self.q = deque([])
	def push(self,i):
		self.q.append(i)
	def pop(self):
		return self.q.popleft()
	def size(self):
		return len(self.q)
	def debug(self):
		return self.q

class Stack():
	def __init__(self):
		self.q = []
	def push(self,i):
		self.q.append(i)
	def pop(self):
		return self.q.pop()
	def size(self):
		return len(self.q)
	def debug(self):
		return self.q

class graph():
	def __init__(self):
		self.graph = defaultdict(list)
	def addnode(self,l):
		f,t = l[0],l[1]
		self.graph[f].append(t)
		self.graph[t].append(f)
	def rmnode(self,l):
		f,t = l[0],l[1]
		self.graph[f].remove(t)
		self.graph[t].remove(f)
	def linked(self,f):
		return self.graph[f]

class dgraph():
	def __init__(self):
		self.graph = defaultdict(set)
	def addnode(self,l):
		f,t = l[0],l[1]
		self.graph[f].append(t)
	def rmnode(self,l):
		f,t = l[0],l[1]
		self.graph[f].remove(t)
	def linked(self,f):
		return self.graph[f]

main()

Submission status: Accepted

Solution code:
#!usr/bin/env python3
from collections import defaultdict,deque
from heapq import heappush, heappop
import sys
import math
import bisect
import random
def LI(): return [int(x) for x in sys.stdin.readline().split()]
def I(): return int(sys.stdin.readline())
def LS():return [list(x) for x in sys.stdin.readline().split()]
def S():
    res = list(sys.stdin.readline())
    if res[-1] == "\n":
        return res[:-1]
    return res
def IR(n):
    return [I() for i in range(n)]
def LIR(n):
    return [LI() for i in range(n)]
def SR(n):
    return [S() for i in range(n)]
def LSR(n):
    return [LS() for i in range(n)]

sys.setrecursionlimit(1000000)
mod = 1000000007

def solve():
    a,b = LI()
    if 1 <= a <= 9 and 1 <= b <= 9:
        print(a*b)
    else:
        print(-1)
    return

#Solve
if __name__ == "__main__":
    solve()

Submission status: Accepted

Solution code:
s=input()
a,b=map(int,s.split())
if a<=9 and b<=9:
    print(a*b)
else:
    print(-1)

Submission status: Accepted

Solution code:
a,b=[int(s) for s in input().split()]
if a<10 and b<10:
  print(a*b)
else:
  print(-1)

Submission status: Accepted

Solution code:
a,b = map(int,input().split())
if a<10 and b<10:
    print(a * b)
else:
    print(-1)

Submission status: Runtime Error

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: Runtime Error

Solution code:
a = int(input());
b = int(input());

if (a >= 1 and a <= 9 and b >= 1 and b <= 9):
  print(a*b)
else:
  print("-1")

Submission status: Runtime Error

Solution code:
A,B = map(int,input().split())
if A<=9 && B<=9:
  print(A*B)
else:
  print(-1)

Submission status: Runtime Error

Solution code:
A = int(input())
B = int(input())
if A<=9 && B<=9:
  print(A*B)
else:
  print(-1)

Submission status: Runtime Error

Solution code:
a, b = map(int(), input().split())

if a < 10 and b < 10:
    print(a * b)
else:
    print(-1)

Submission status: Runtime Error

Solution code:
a,b = map(int,input())
print(a*b if a<=9 and b<=9 else -1)

Submission status: Runtime Error

Solution code:
#include <bits/stdc++.h>
using namespace std;
//#include <atcoder/dsu>
//using namespace atcoder;

typedef long long int ll;
#define rep(i,n) for (int i = 0; i < (n); i++)
#define all(v) (v).begin(), (v).end()
#define sz(x) int(x.size())
const ll mod = 1000000007;
const ll INF = 1001001001001001000;

int main() {
    int a,b; cin >> a >> b;
    if (a >= 10 || b >= 10) cout << -1 << endl;
    else cout << a*b << endl;
    return 0;
}

Submission status: Runtime Error

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

if 1<=A,B<=9:
  print(A*B)
else:
  print(-1)

Submission status: Runtime Error

Solution code:
a = int(input())
if a % 1 == 0 or a % 2 == 0 or a % 3 == 0 or a % 4 == 0 or a % 5 == 0 or a % 6 == 0 or a % 7 == 0 or a % 8 == 0 or a % 9 == 0:
  print('Yes')
else:
  print('No')

Submission status: Runtime Error

Solution code:
a, b = int(input().split())

if a < 10 and b < 10:
    print(a * b)
else:
    print(-1)

Submission status: Runtime Error

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

print(A*B)

Submission status: Runtime Error

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

Submission status: Runtime Error

Solution code:
#ABC144A
a,b = map(int,input().split())
print(a*b if 1<=a<=9 ans 1<=b<=9 else -1)

Submission status: Runtime Error

Solution code:
N = int(input())

for i in range(1, 9 + 1, ):
    q, mod = divmod(N, i)
    if q <= 9 and mod == 0:
        print('Yes')
        exit()

print('No')

Submission status: Runtime Error

Solution code:
N = int(input())
 
for i in range(1, 9 + 1, ):
    q, mod = divmod(N, i)
    if q <= 9 and mod == 0:
        print('Yes')
        exit()

print('No')

Submission status: Runtime Error

Solution code:
n=int(input())
for i in range(9):
    for j in range(9):
        k = (i+1)*(j+1)
        if n%k==0:
            print('Yes')
        else:
            print('No')

Submission status: Runtime Error

Solution code:
S = int(input())

def divisor(n): 
    i = 1
    table = []
    while i * i <= n:
        if n%i == 0:
            table.append(i)
            table.append(n//i)
        i += 1
    table = list(set(table))
    return table

divisors = divisor(S)

#print(divisors)
n = len(divisors)

for i in range(int(n / 2+n % 2)):
    #print(divisors[i])
    if S // divisors[i] <= 9:
        result ="Yes"
    else:
        result ="No"
print(result)

Submission status: Runtime Error

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

Submission status: Runtime Error

Solution code:
# coding: utf-8
# Your code here!
n=int(input())
flag=0
for i in range(1,10):
    if n%i==0:
        flag=1
if flag:
    print('Yes')
else:
    print('No')

Submission status: Runtime Error

Solution code:
A,B=int(input())
if A*B<=81:
    print("A*B")
else:
    print("-1")

Submission status: Runtime Error

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: Runtime Error

Solution code:
n=int(input())
l=list()
if n<=5:
  print("Yes")
  exit()
for i in range(2, n//2+1):
    if n % i == 0: 
        if (n//i,i) not in l:
            l.append((i,n//i))
flag=0
for i in l:
    if i[0]<=9 and i[1]<=9:
        flag=1
        print("Yes")
        exit()
if not flag:
    print("No")

Submission status: Runtime Error

Solution code:
a.b = list(map(int, input().split( )))
if 1 <= a <= 9 and 1 <= b <= 9:
  print(a*b)
else:
  print(-1)

Submission status: Runtime Error

Solution code:
A,B=map(int,input(),split())
if A<=9 and B<=9:
    print(A*B)
else:
    print(-1)

Submission status: Runtime Error

Solution code:
A,B=map(int,input(),split())
if 1<=A<=9 and 1<=B<=9:
    print(A*B)
else:
    print(-1)

Submission status: Runtime Error

Solution code:
n=int(input())
#a,b,c=map(int,input().split())
t=0
flag=False
for i in range(1,9):
    for j in range(1,9):
        if n==i*j:
            print('Yes')
            t+=1
            flag=True
            break
    if flag:
        break

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

Submission status: Runtime Error

Solution code:
n=int(input())
#a,b,c=map(int,input().split())
i=0
t=0
flag=False
for i in range(10):
    for j in range(10):
        if n==i*j:
            print('Yes')
            t+=1
            flag=True
            break
    if flag:
        break

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

Submission status: Runtime Error

Solution code:
n=int(input())
#a,b,c=map(int,input().split())
i=0
t=0
flag=False
while i<=10:
    for j in range(10):
        if n==i*j:
            print('Yes')
            t=1
            flag=True
            break
    i+=1
    if flag:
        break

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

Submission status: Runtime Error

Solution code:
n=int(input())
#a,b,c=map(int,input().split())
i=0
flag=False
while i<=10:
    for j in range(10):
        if n==i*j:
            print('Yes')
            flag=True
            break
    i+=1
    if flag==False:
        print('No')
        break

Submission status: Runtime Error

Solution code:
S = list(input())
if len(S) > 3:
    print(int(S[0]) * int(S[1]))
else:
    print(-1)

Submission status: Runtime Error

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

Submission status: Runtime Error

Solution code:
n = int(input())
a = 0
for i in range(1,10):
    if n % i != 0:
        continue
    else:
        if n / i <= 9:
            a += 1
            break
        else:
            continue
if a == 1:
    print('Yes')
else:
    print('No')

Submission status: Runtime Error

Solution code:
n = int(input())
a = 0
for i in range(1,10):
    if n % i != 0:
        continue
    else:
        if n / i <= 9:
            a += 1
            break
        else:
            continue
if a == 1:
	print('Yes')
else:
	print('No')

Submission status: Runtime Error

Solution code:
n = int(input())
a = 0
for i in range(1,10):
	if n % i != 0:
        continue
    else:
        if n / i <= 9:
            a += 1
            break
        else:
            continue
if a == 1:
	print('Yes')
else:
	print('No')

Submission status: Runtime Error

Solution code:
print("Input A")
a = int(input())
print("Input B")
b = int(input())

print("Input result")
c = int(input())

if c = a*b:
  print a*b
else:
  print ("-1")

Submission status: Runtime Error

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

for i in range(1,10):
    if n%i == 0:
        div = n/i
        if div>=1 and div<=9:
            flag = 1
            break

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

Submission status: Runtime Error

Solution code:
a,b = map(input().split())
if a > 9 or b > 9:
  print(-1)
  exit()
print(a*b)

Submission status: Runtime Error

Solution code:
import bisect,collections,copy,heapq,itertools,math,string
import numpy as np
import sys
sys.setrecursionlimit(10**7)

def _S(): return sys.stdin.readline().rstrip()
def I(): return int(sys.stdin.readline().rstrip())
def LI(): return list(map(int,sys.stdin.readline().rstrip().split()))
def LS(): return list(sys.stdin.readline().rstrip().split())

# 最短距離
# 素因数分解
N = I()

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)

    divisors.sort()
    return divisors

# c = sympy.divisors(N)
c = make_divisors(N)
lenc = len(c)
if (lenc % 2)==0:
    a = c[lenc // 2 - 1]
    b = c[lenc // 2]
else:
    a = c[lenc // 2]
    b = a

print(a + b -2)

#H,N = LI()
#AB = [LI() for _ in range(N)]
#A,B = zip(*AB)
#Ap = np.array(A)
#C = np.zeros(N + 1)

# if ans:
#     print('Yes')
# else:
#     print('No')

Submission status: Runtime Error

Solution code:
a,b=map(int,input())
if 1<=a<=9 and 1<=b<=9:
    print(a*b)
else:
    print(-1)

Submission status: Runtime Error

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

Submission status: Runtime Error

Solution code:
N = int(input())
kuku = []
for x in range(1,10):
  for y in range(1,10):
    kuku.append(x*y)
    
if N in kuku:
  print('Yes')
else:
  print('No')

Submission status: Runtime Error

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

Submission status: Runtime Error

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

Submission status: Runtime Error

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

Submission status: Runtime Error

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

han=999999999999999999999999999999999999999999
b=0



for a in range(1,int(math.sqrt(N))+1):
    if N%a==0:
        A=N/a
        if A>a:
            gou=A-a
        else:
            gou=a-A
        b=a
        if gou<han:
            han=gou
            kot=A+a
if b==A:
    print(int(kot)-1)
else:
    print(int(kot)-2)

Submission status: Runtime Error

Solution code:
n = int(input())

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

Submission status: Runtime Error

Solution code:
n=int(input())

steps = []

for x in range(n):
  if n % (x+1)==0:
    steps.append(x+n//(x+1)-1)

print(steps)

Submission status: Runtime Error

Solution code:
n = int(input))

for x in range(n):
  	if n % (x + 1)== 0:
      step.append(x+n//(x;1)+1)
      
      print(min(steps)
   ping

Submission status: Runtime Error

Solution code:
s = raw_input()
a,b = s.split('/')
a,b = int(a),int(b)

def mul(a,b):
    if a <= 9 and a >=1 and (1 <= b <= 9):
        return a * b
    else:
        return -1

print mul(a,b)

Submission status: Runtime Error

Solution code:
s = raw_input()
a,b = s.split('/')
a,b = int(a),int(b)

def mul(a,b):
    if a <= 9 and a >=1 and (1 <= b <= 9):
        return a * b
    else:
        return -1

print(mul(a,b))

Submission status: Runtime Error

Solution code:
s = raw_input()
a,b = s.split('/')
a,b = int(a),int(b)

def mul(a,b):
    if a <= 9 and a >=1 and (1 <= b <= 9):
        return a * b
    else:
        return -1

return mul(a,b)

Submission status: Runtime Error

Solution code:
s = raw_input()
a,b = s.split('/')
a,b = int(a),int(b)

def mul(a,b):
    if a <= 9 and a >=1 and (1 <= b <= 9):
        return a * b
    else:
        return -1

mul(a,b)

Submission status: Runtime Error

Solution code:
s = raw_input()
    n = int(raw_input())

    a,b = s.split(' ')
    a,b = int(a),int(b)

    if a <= 9 and a >=1 and (1 <= b <= 9):
        return a * b
    else:
        return -1

Submission status: Runtime Error

Solution code:
N = int(input())

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

Submission status: Runtime Error

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

for i in range(1,10):
  for j in range(1,10):
    if i*j == num:
      print('Yes')
      flag = True
if not flag:      
	print('No')

Submission status: Runtime Error

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

Submission status: Runtime Error

Solution code:

#素因数分解
def prime_factorization(N):
    n=N
    a=2
    prime_factor=[]
    while a**2<=n:
        while n%a==0:
            prime_factor.append(a)
            n//=a
        a+=1
    if n>1:
        prime_factor.append(n)
    return prime_factor


N=int(input())

a=1
b=N//a
dis=abs(b-a)

for i in range(1,int(N**0.5)+1):
    if N%i==0:
        _a=i
        _b=N//i
        _dis=abs(_b-_a)
        if _dis<dis:
            a=_a
            b=_b
            dis=_dis

print(a-1+b-1)

Submission status: Runtime Error

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

Submission status: Runtime Error

Solution code:
a, b = map(int, input().split())
if 1 <= a and a <= 9 and 1 <= b nd b <= 9:
  print(a*b)
else:
  print(-1)

Submission status: Runtime Error

Solution code:
n = int(input())
maxn = int(n ** 0.5)
for i in range(maxn):
    p = maxn - i
    if n % p == 0:
        q = n // p
        break
print(p + q - 2)

Submission status: Runtime Error

Solution code:
A, B = map(int.input().split())
if (0<=A<=9) and (0<=B<=9):
  print(A*B)
else:
  print(-1)

Submission status: Runtime Error

Solution code:
a1=input()
a2=[i for i in a1.split()]
x,y=float(a2[0]),float(a2[1])
v,v1=x.is_integer(),y.is_integer()
if 1<=(x and y)<=20 and v1==v2==True:
    if 1<=(x and y)<=9:
        print(int(x*y))
    else:
        print('-1')

Submission status: Runtime Error

Solution code:
a=int(input("1から9の間の整数:"))
b=int(input("1から9の間の整数:"))
if a>=1 and a<=9 and b>=1 and b<=9:
    m=a*b
    print("計算結果は{}です".format(m))
else:
    print("-1")
print()

Submission status: Runtime Error

Solution code:
a,b = map(int, input().split())
if (a<10 && b<10):
      print(a*b)
else:
      print(-1)

Submission status: Runtime Error

Solution code:
#n=int(input())
n,m=input_list()
#a=input_list()
if n>9 or m>9:
    print(-1)
    exit()

print(n*m)

Submission status: Runtime Error

Solution code:
a,b = map(int,input().split())
if 1<=a<=9 and 1<=b<=9:
  print(a*b)
else:
  prit(-1)

Submission status: Runtime Error

Solution code:
print((lambda x:('Yes' if (x[0] <= 9 and x[1] <= 9) else 'No'))(list(map(int,input().split())))))

Submission status: Runtime Error

Solution code:
print(lambda x:('Yes' if (x[0] <= 9 and x[1] <= 9) else 'No')(list(map(int,input().split())))))

Submission status: Runtime Error

Solution code:
A,B = int(input())
print(A*B if A<= 9 and B <=9 else -1)

Submission status: Runtime Error

Solution code:
import math
a,b,x=map(int,input().split())
if a**2*b>=2*x:
  ans=math.degrees(math.atan(2*x/(a*b**2)))
  print(90-ans)
else:
  ans=math.degrees(math.atan(a**2/(2*a*b-2*x/a)))
  print(90-ans)

Submission status: Runtime Error

Solution code:
a,b=map(int,input())
if max(a,b)<=9 and min(a,b)>=1:
    print(a*b)
else:print(-1)

Submission status: Runtime Error

Solution code:
a,b=map(int,input().split())
if len(a)==1 and len(b)==1:
  print(a*b)
else:
  print(-1)

Submission status: Runtime Error

Solution code:
/*
ID: learnin7
TASK: test
LANG: C++                 
*/
/* LANG can be C++11 or C++14 for those more recent releases */
#include<bits/stdc++.h>

/*  Macros from Endagorion */
#define mp make_pair
#define mt make_tuple
#define fi first
#define se second
#define pb push_back
#define all(x) (x).begin(), (x).end()
#define rall(x) (x).rbegin(), (x).rend()
#define forn(i, n) for (int i = 0; i < (int)(n); ++i)
#define for1(i, n) for (int i = 1; i <= (int)(n); ++i)
#define ford(i, n) for (int i = (int)(n) - 1; i >= 0; --i)
#define fore(i, a, b) for (int i = (int)(a); i <= (int)(b); ++i)

using namespace std;

typedef pair<int, int> pii;
typedef vector<int> vi;
typedef vector<pii> vpi;
typedef vector<vi> vvi;
typedef long long i64;
typedef vector<i64> vi64;
typedef vector<vi64> vvi64;
typedef pair<i64, i64> pi64;
typedef double ld;


int main(){
        
    ios_base::sync_with_stdio(0);
    
    //ofstream fout ("test.out");
    //ifstream fin ("test.in");
    //fin >> a >> b;
    //fout << a+b << endl;
    int a,b;
    cin>>a>>b;
    if(a<=9 && b<=9)    cout<<a*b<<endl;
    else                cout<<-1<<endl;
    return 0;
}

Submission status: Runtime Error

Solution code:
import sys
import heapq
import re
from itertools import permutations
from bisect import bisect_left, bisect_right
from collections import Counter, deque
from math import factorial, sqrt, ceil, gcd
from functools import lru_cache, reduce
INF = 1 << 60
MOD = 1000000007
sys.setrecursionlimit(10 ** 7)

# UnionFind
class UnionFind():
    def __init__(self, n):
        self.n = n
        self.parents = [-1] * n

    def find(self, x):
        if self.parents[x] < 0:
            return x
        else:
            self.parents[x] = self.find(self.parents[x])
            return self.parents[x]

    def union(self, x, y):
        x = self.find(x)
        y = self.find(y)

        if x == y:
            return

        if self.parents[x] > self.parents[y]:
            x, y = y, x

        self.parents[x] += self.parents[y]
        self.parents[y] = x

    def size(self, x):
        return -self.parents[self.find(x)]

    def same(self, x, y):
        return self.find(x) == self.find(y)

    def members(self, x):
        root = self.find(x)
        return [i for i in range(self.n) if self.find(i) == root]

    def roots(self):
        return [i for i, x in enumerate(self.parents) if x < 0]

    def group_count(self):
        return len(self.roots())

    def all_group_members(self):
        return {r: self.members(r) for r in self.roots()}

    def __str__(self):
        return '\n'.join('{}: {}'.format(r, self.members(r)) for r in self.roots())

# ダイクストラ
def dijkstra_heap(s, edge, n):
    #始点sから各頂点への最短距離
    d = [10**20] * n
    used = [True] * n #True:未確定
    d[s] = 0
    used[s] = False
    edgelist = []
    for a,b in edge[s]:
        heapq.heappush(edgelist,a*(10**6)+b)
    while len(edgelist):
        minedge = heapq.heappop(edgelist)
        #まだ使われてない頂点の中から最小の距離のものを探す
        if not used[minedge%(10**6)]:
            continue
        v = minedge%(10**6)
        d[v] = minedge//(10**6)
        used[v] = False
        for e in edge[v]:
            if used[e[1]]:
                heapq.heappush(edgelist,(e[0]+d[v])*(10**6)+e[1])
    return d

# 素因数分解
def factorization(n):
    arr = []
    temp = n
    for i in range(2, int(-(-n**0.5//1))+1):
        if temp%i==0:
            cnt=0
            while temp%i==0:
                cnt+=1
                temp //= i
            arr.append([i, cnt])

    if temp!=1:
        arr.append([temp, 1])

    if arr==[]:
        arr.append([n, 1])

    return arr

# 2数の最小公倍数
def lcm(x, y):
    return (x * y) // gcd(x, y)

# リストの要素の最小公倍数
def lcm_list(numbers):
    return reduce(lcm, numbers, 1)

# リストの要素の最大公約数
def gcd_list(numbers):
    return reduce(gcd, numbers)

# 素数判定
def is_prime(n):
    if n <= 1:
        return False
    p = 2
    while True:
        if p ** 2 > n:
            break
        if n % p == 0:
            return False
        p += 1
    return True


# limit以下の素数を列挙
def eratosthenes(limit):
    A = [i for i in range(2, limit+1)]
    P = []

    while True:
        prime = min(A)
        
        if prime > sqrt(limit):
            break
            
        P.append(prime)
            
        i = 0
        while i < len(A):
            if A[i] % prime == 0:
                A.pop(i)
                continue
            i += 1
            
    for a in A:
        P.append(a)
            
    return P

# 同じものを含む順列
def permutation_with_duplicates(L):

    if L == []:
        return [[]]

    else:
        ret = []

        # set（集合）型で重複を削除、ソート
        S = sorted(set(L))

        for i in S:

            data = L[:]
            data.remove(i)

            for j in permutation_with_duplicates(data):
                ret.append([i] + j)

        return ret


# ここから書き始める
a, b = map(int, input().split())
if 1 <= a <= 9 and 1 <= b <= 9:
    print(a * b)
else:
    print(-1)

Submission status: Runtime Error

Solution code:
a,b  = int(input().split())
print(a*b)

Submission status: Runtime Error

Solution code:
a=int(input())
b=int(input())
if a>9 or b>9:
    print(-1)
print(a*b)

Submission status: Runtime Error

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

Submission status: Runtime Error

Solution code:
a,b=(int,input().split())
if a<10 and b<10:
  print(a*b)
  
else:
  print('-1')

Submission status: Runtime Error

Solution code:
a,b=(int,input().split())
if a<10 and b<10:
  print(a*b)
  
else:
  print(-1)

Submission status: Runtime Error

Solution code:
A,B = map(int, input().split())  
if A<=9 && B<=9:
  print(A*B)
else:
  print(-1)

Submission status: Runtime Error

Solution code:
import math
a,b,x = map(int,input().split())
ku = math.atan(2*(b/a)-2*x/a**3)
kuku = math.degrees(ku)
if kuku <= 45:
  print(kuku)
else:
  print(math.degrees(math.atan(a*b**2/(2*x))))

Submission status: Runtime Error

Solution code:
A, B = A, B = map(int, input().split())
if 1 <= A <= 9 and 1 <= B <= 9:
  print(A*B)
else:
  print(-1)

Submission status: Runtime Error

Solution code:
import math

def judge(n):
  if float.is_integer(math.sqrt(n)):
    return "Yes"
  else:
    return "No"
  
print(judge(int(input())))

Submission status: Runtime Error

Solution code:
N = int(input())

f = 0
for i in range(1,10):
  for j in range(1,10):
    if i*j == N:
      f = 1
      break
  if f == 1:
    break
if f == 0:
  print("NO")
else:
  print("YES")

Submission status: Runtime Error

Solution code:
a = list(map(int, input().split()))

print(a[0]*a[1] if a[0],a[1]<=9 else -1)

Submission status: Runtime Error

Solution code:
s=input();print([int(s[0])*int(s[2]),-1][len(s)!=3])

Submission status: Runtime Error

Solution code:
A,B = int(input()),int(input())

if A>9 or B>9:
  print(-1)
else:
  print(A*B)

Submission status: Runtime Error

Solution code:
a,b,=int(input())
if a>=10 or b>=10:
    print(-1)
    break:
else:
    print(a*b)

Submission status: Runtime Error

Solution code:
a,b=map(int,input().split())
if 1<=a,b<=9:
    print(a*b)
    else:
    print(-1)

Submission status: Runtime Error

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

Submission status: Runtime Error

Solution code:
a = int(input())
b = int(input())
if a<10 and b<10:
  print(a*b)

  
else:
  print('-1')

Submission status: Runtime Error

Solution code:
a = int(input())
b = int(input())
if a<10 and b<10:
  print(a*b)
  
else:
  print('-1')

Submission status: Runtime Error

Solution code:
a = int(input())
b = int(input())
if a<10 and b<10:
  print(a*b)
  
else:
  print('-1')

Submission status: Runtime Error

Solution code:
a,b = map(int,input())
if a<10 and b<10:
  print(a*b)
  
else:
  print('-1')

Submission status: Runtime Error

Solution code:
N = int(input())
ans = 1 + N - 2 #求めるのは(x-1) + (y-1)の最小値
for i in range(1, int(N**0.5)+1):
    if N%i==0:
        ans = min(ans, i+N//i-2)
print(ans)

Submission status: Runtime Error

Solution code:
A,B = map(int,input())
if 1<=A<=9 and 1<=B<=9:
  print(A*B)
else:
  print("-1")