import * as fs from 'fs'

const reader = (data: string) => data.split(' ').map(t => parseInt(t, 10))

function Main(input) {
  const [A, B] = reader(input)

  console.log(A * B <= 81 ? A * B : -1)
}

Main(fs.readFileSync('/dev/stdin', 'utf8'))
