#include <bits/stdc++.h>
using namespace std;
bool debug = false;
int best, n, m;
bool used[45][45];
int dx[5] = {0, 0, 1, -1, 0}, dy[5] = {1, -1, 0, 0, 0};
void dfs(int x) {
  vector<pair<int, int> > tmp;
  int xi = -1, yi = -1;
  for (int i = 0; i < n; i++) {
    for (int j = 0; j < m; j++) {
      if (used[i][j] == false) {
        xi = i;
        yi = j;
        break;
      }
    }
    if (xi != -1 || yi != -1) {
      break;
    }
  }
  if (xi == -1 && yi == -1) {
    best = x;
    return;
  }
  if (x + 1 >= best) {
    return;
  }
  for (int i = 0; i < 5; i++) {
    int sx = xi + dx[i], sy = yi + dy[i];
    if (sx >= 0 && sx < n && sy >= 0 && sy < m) {
      tmp.clear();
      for (int j = 0; j < 5; j++) {
        int nx = sx + dx[j], ny = sy + dy[j];
        if (nx >= 0 && nx < n && ny >= 0 && ny < m && !used[nx][ny]) {
          tmp.push_back(make_pair(nx, ny));
          used[nx][ny] = true;
        }
      }
      if (debug) cout << "{" << endl;
      dfs(x + 1);
      if (debug) cout << "}" << endl;
      for (int j = 0; j < tmp.size(); j++) {
        used[tmp[j].first][tmp[j].second] = false;
      }
    }
  }
}
int main(int argc, char* argv[]) {
  cin >> n >> m;
  best = n * m;
  dfs(0);
  cout << n * m - best;
  return 0;
}
