a,b=list(map(int,input().split()))



if a<10 and b<10:

  print((a*b))

else:

  print((-1))
a,b=list(map(int,input().split()))

print(((-1,a*b)[a<10 and b<10]))

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

a, b = list(map(int, input().split()))
print(((-1, a * b)[a < 10 and b < 10]))

-if a < 10 and b < 10: -    print((a * b)) -else: -    print((-1)) +print(((-1, a * b)[a < 10 and b < 10]))