#include <bits/stdc++.h>
#pragma GCC optimize("O3")
const double pi = acos(-1);
const int MOD = 1e9 + 7;
const int INF = 1e9 + 7;
const int MAXN = 1e6 + 5;
const double eps = 1e-9;
using namespace std;
int f(int x) { return (-2 * x * x * x + 9 * x * x - 12 * x) / 3; }
int main() {
  int n, m;
  scanf("%d", &(n)), scanf("%d", &(m));
  if (n > m) swap(n, m);
  if (n == 1) return !printf("%d\n", (m));
  if (n == 2) return !printf("%d\n", ((m / 4) * 4 + min((m % 4), 2) * 2));
  printf("%d\n", (m * n - (m * n) / 2));
  return 0;
}
