program beg
 
implicit double Precision (A-H,O-Z)
integer N,M,sum,ama,cnt
read *,N,M
 
cnt=0
do i=1,N
	do j=1,M
    sum=2*N+M
    ama=mod(sum,2)
    if(ama == 0)then
    cnt=cnt+1
    end if
    end do
end do 
print *,cnt
 
end program beg