#include <bits/stdc++.h>
using namespace std;
const int N = 2e5 + 10;
const int inf = 1e9;
int dp[45][1 << 6][1 << 6];
int row, col;
void self_max(int &a, int b) { a = max(a, b); }
int solve(int nwcol, int up, int now) {
  if (dp[nwcol][up][now] != -1) return dp[nwcol][up][now];
  int &alias = dp[nwcol][up][now];
  if (nwcol == col - 1) {
    for (int j = 0; j < row; ++j) {
      int ok = 0;
      for (int k = -1; k < 2; ++k) {
        int c = j + k;
        if (c < 0 || c >= row) continue;
        if (now & (1 << c)) {
          ok = 1;
          break;
        }
      }
      if (up & (1 << j)) ok = 1;
      if (!ok) {
        return alias = -inf;
      }
    }
    alias = 0;
    for (int j = 0; j < row; ++j) {
      if (!(now & (1 << j))) ++alias;
    }
    return alias;
  } else {
    alias = -inf;
    for (int mask = 0; mask < (1 << row); ++mask) {
      int maskok = 1;
      for (int r = 0; r < row; ++r) {
        int ok = 0;
        for (int k = -1; k < 2; ++k) {
          int rr = r + k;
          if (rr < 0 || rr >= row) continue;
          if ((now & (1 << rr))) {
            ok = 1;
            break;
          }
        }
        if ((up & (1 << r))) ok = 1;
        if ((mask & (1 << r))) ok = 1;
        if (!ok) {
          maskok = 0;
          break;
        }
      }
      if (!maskok) continue;
      int jml = solve(nwcol + 1, now, mask);
      for (int r = 0; r < row; ++r)
        if (!(now & (1 << r))) ++jml;
      self_max(alias, jml);
    }
  }
  return alias;
}
int main() {
  cin >> row >> col;
  if (row > col) swap(row, col);
  memset(dp, -1, sizeof(dp));
  int ret = -inf;
  for (int i = 0; i < (1 << row); ++i) self_max(ret, solve(0, 0, i));
  cout << ret << "\n";
  return 0;
}
