#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, m;
  scanf("%d%d", &n, &m);
  if (n > m) swap(n, m);
  if (n < 2)
    printf("%d\n", m);
  else if (n == 2) {
    int ret = 0;
    ret += (m / 4) * 4;
    ret += min(2, m % 4) * 2;
    printf("%d\n", ret);
  } else
    printf("%d\n", (n * m + 1) / 2);
  return 0;
}
