#include <bits/stdc++.h>
using namespace std;
static const double EPS = 1e-9;
int ROUND(double x) { return (int)(x + 0.5); }
bool ISINT(double x) { return fabs(ROUND(x) - x) <= EPS; }
bool ISEQUAL(double x, double y) {
  return fabs(x - y) <= EPS * max(1.0, max(fabs(x), fabs(y)));
}
double SQSUM(double x, double y) { return x * x + y * y; }
template <class T>
bool INRANGE(T x, T a, T b) {
  return a <= x && x <= b;
}
int bitCount(int i) {
  int tmp = i;
  int count = 0;
  while (tmp) {
    tmp &= tmp - 1;
    count++;
  }
  return count;
}
int main() {
  int W, H;
  while (scanf("%d %d", &W, &H) != EOF) {
    if (W > H) {
      swap(W, H);
    }
    if (W == 1 && H == 1) {
      printf("0\n");
    } else {
      vector<vector<int> > dp(H, vector<int>(1 << (2 * W), (987654321)));
      for (int i = 0; i < 1 << (2 * W); i++) {
        dp[0][i] = bitCount(i);
      }
      for (int y = 1; y < H; y++) {
        for (int last = 0; last < 1 << (2 * W); last++) {
          for (int now = 0; now < 1 << W; now++) {
            const int last2 = last >> W;
            const int last1 = last & ((1 << W) - 1);
            int kimatta1 = last2;
            for (int x = 0; x < W; x++) {
              if (last1 & (1 << x)) {
                kimatta1 |= 1 << (x + 1);
                kimatta1 |= 1 << (x);
                kimatta1 |= 1 << (x - 1);
              }
            }
            bool ok = true;
            for (int x = 0; x < W; x++) {
              if (!(now & (1 << x)) && !(kimatta1 & (1 << x))) {
                ok = false;
                break;
              }
            }
            if (H - 1 == y) {
              int now_kimatta = (now << 1) | now | (now >> 1) | last1;
              int zenume = (1 << W) - 1;
              if ((now_kimatta & zenume) != zenume) {
                ok = false;
              }
            }
            if (ok) {
              const int new_last = (last1 << W) | now;
              const int new_value = dp[y - 1][last] + bitCount(now);
              dp[y][new_last] = min(dp[y][new_last], new_value);
            }
          }
        }
      }
      int ret = (987654321);
      for (int last = 0; last < 1 << (2 * W); last++) {
        ret = min(ret, dp[H - 1][last]);
      }
      ret = W * H - ret;
      printf("%d\n", ret);
    }
  }
}
