program beg

implicit double Precision (A-H,O-Z)
integer N,M,sum,RR,cnt
read *,N,M

cnt=0
do i=1,N
	do j=1,M
    sum=2*N+M
    RR=mod(sum,2)
    if (RR == 0)
    cnt=cnt+1
    endif
    end do
end do 
print *,cnt

end program beg