#include <bits/stdc++.h>
using namespace std;
const double PI = acos(-1.0);
const long long MOD = 1e9 + 7;
const unsigned long long INF = 1e18;
const int dx[]{1, -1, 0, 0}, dy[]{0, 0, 1, -1};
long long gcd(long long, long long);
bool isEven(long long);
void coutY();
void coutN();
int main() {
  int a, b;
  cin >> a >> b;
  if (a * b <= 81 && a * b >= 1) {
    cout << a * b << endl;
  } else {
    cout << -1 << endl;
  }
}
long long gcd(long long a, long long b) {
  if (a == 0 || b == 0) return 0;
  if (a < b) swap(a, b);
  if (a % b == 0)
    return b;
  else
    gcd(b, a % b);
}
bool isEven(long long a) { return !((bool)(a % 2)); }
void coutY() {
  cout << "Yes" << endl;
  return;
}
void coutN() {
  cout << "No" << endl;
  return;
}
