#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, m;
  scanf("%d %d", &n, &m);
  int maxi =
      max(m + (n - 1) / 3 * m +
              ((n - 1) % 3 > 0 && m < 4 ? (m == 1 || m == 3 ? 1 : 2) : 0),
          n + (m - 1) / 3 * n +
              ((m - 1) % 3 > 0 && n < 4 ? (n == 1 || n == 3 ? 1 : 2) : 0));
  int maxi_2 = 0;
  for (int i = 0; i < n; i++) {
    if (i & 1) {
      maxi_2 += m / 2;
    } else {
      maxi_2 += (m - 1) / 2 + 1;
    }
  }
  int maxi_3 = 0;
  for (int i = 0; i < n; i++) {
    if (i & 1) {
      maxi_3 += (m - 1) / 2 + 1;
    } else {
      maxi_3 += m / 2;
    }
  }
  int maxi_4 = 0;
  int k = (n == 2 ? m : (m == 2 ? n : -1));
  for (int i = 0; i < k; i += 4) {
    if (i + 1 < k)
      maxi_4 += 4;
    else
      maxi_4 += 2;
  }
  maxi = max(maxi, max(maxi_2, maxi_3));
  maxi = max(maxi, maxi_4);
  printf("%d", maxi);
  return 0;
}
