#include <bits/stdc++.h>
using namespace std;
int main() {
  long long A, B;
  cin >> A >> B;
  if (A < 0 || A > 10 || B < 0 || B > 10) {
    cout << "-1" << endl;
  } else {
    cout << A * B << endl;
  }
  return 0;
}
