#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, m;
  cin >> n >> m;
  int count = 0;
  if (n == 1) {
    count = m;
  } else if (m == 1) {
    count = n;
  } else if (n == 2 && m == 2) {
    count = 4;
  } else if ((n == 2 && m == 3) || (n == 3 && m == 2)) {
    count = 4;
  } else if (n == 2 && m > 3) {
    count = (m / 4) * 4;
    if ((m % 4) == 1) {
      count += 2;
    } else if ((m % 4) == 2 || (m % 4) == 3) {
      count += 4;
    }
  } else if (m == 2 && n > 3) {
    count = (n / 4) * 4;
    if ((n % 4) == 1) {
      count += 2;
    } else if ((n % 4) == 2 || (n % 4) == 3) {
      count += 4;
    }
  } else {
    if (((m % 2) == 0) || ((n % 2) == 0)) {
      count = m * n / 2;
    } else {
      count = ((m / 2) + 1) * ((n / 2) + 1) + (m / 2) * (n / 2);
    }
  }
  cout << count;
  return 0;
}
