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



if 9>=a and a>=1 and 9>=b and b>=1:

  print((a*b))

else:

  print((-1))

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



if a>=1 and 9>=a and b>=1 and 9>=b:

  print((a * b))

else:

  print((-1))

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

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

-if 9 >= a and a >= 1 and 9 >= b and b >= 1: +if a >= 1 and 9 >= a and b >= 1 and 9 >= b: