#include<iostream>
using namespace std;
int main(){
	int n,m,r;
	cin>>n>>m;
	if(n==m){
		r=m*n-((m-1)/2)*((n-1)/2)-((n-2)/2)*((m-2)/2);
		cout<<r<<endl;
	}else if(n==3){
		r=m*n-m/2;
		cout<<r<<endl;
	}
}