#include <bits/stdc++.h>
using namespace std;
int main() {
  int i, j, n, m, res;
  while (scanf("%d%d", &n, &m) != EOF) {
    if (n == 1 && m == 1)
      res = 1;
    else if (n == 1)
      res = m;
    else if (m == 1)
      res = n;
    else if (n == 2 && m == 2 || n == 2 && m == 3 || n == 3 && m == 2)
      res = 4;
    else if (n == 2) {
      if (m % 2 == 1) {
        int tk = (m + 1) / 2;
        res = tk * 2;
      } else {
        int tk;
        if (m % 4)
          tk = m / 4 + 1;
        else
          tk = m / 4;
        res = tk * 4;
      }
    } else if (m == 2) {
      if (n % 2 == 1) {
        int tk = (n + 1) / 2;
        res = tk * 2;
      } else {
        int tk;
        if (n % 4)
          tk = n / 4 + 1;
        else
          tk = n / 4;
        res = tk * 4;
      }
    } else {
      if (n < m) {
        int t = n;
        n = m;
        m = t;
      }
      if (n % 2 == 1) {
        if (m % 2 == 1) {
          int tk = (n + 1) / 2;
          int num = m / 2 + 1;
          res = num * tk + (m - num) * (tk - 1);
        } else {
          int tk = (n + 1) / 2;
          int num = m / 2;
          res = (tk + tk - 1) * num;
        }
      } else {
        int tk = n / 2;
        res = tk * m;
      }
    }
    printf("%d\n", res);
  }
  return 0;
}
