#include <bits/stdc++.h>
using namespace std;
template <typename T>
void mymax(T &_a, T _b) {
  if (_a < _b) _a = _b;
}
template <typename T>
void mymin(T &_a, T _b) {
  if (_a > _b) _a = _b;
}
template <typename T>
void print(T _x) {
  for (auto _it = _x.begin(); _it != _x.end(); _it++) cout << *_it << " ";
  cout << endl;
}
void print(int _x) { printf("%d ", _x); }
void print(long long _x) { printf("%lld ", _x); }
int n, m;
int juji[45][45];
int ans = (1000000000);
bool check(int jie) {
  for (int i = 1; i <= jie; i++)
    for (int j = 1; j <= m; j++)
      if (juji[j][i] == 0) return 0;
  return 1;
}
void dfs(int x, int y, int nowjuji) {
  if (y == n + 1) {
    if (check(n)) {
      ans = min(ans, nowjuji);
    }
    return;
  }
  if (nowjuji > (m * y) / 3) return;
  if (nowjuji >= ans) return;
  if (x == m) {
    if (y - 2 >= 1 && !check(y - 2)) return;
    dfs(1, y + 1, nowjuji);
  } else
    dfs(x + 1, y, nowjuji);
  juji[x - 1][y]++;
  juji[x][y - 1]++;
  juji[x + 1][y]++;
  juji[x][y + 1]++;
  juji[x][y]++;
  if (x == m)
    dfs(1, y + 1, nowjuji + 1);
  else
    dfs(x + 1, y, nowjuji + 1);
  juji[x - 1][y]--;
  juji[x][y - 1]--;
  juji[x + 1][y]--;
  juji[x][y + 1]--;
  juji[x][y]--;
}
int main() {
  memset(juji, 0, sizeof(juji));
  scanf("%d %d", &n, &m);
  if (n < m) swap(n, m);
  dfs(1, 1, 0);
  printf("%d\n", n * m - ans);
  return 0;
}
