program example
	implicit none

	integer(8) H,W
    
    read(*,*) H,W
    
    if(W==1 .or. H==1) then
    	write(*,*) 1
        
    else if (mod(H,2)==0) then
    	write(*,*) W*(H/2)
        
    else

    	write(*,*) (W*(H/2))+(W/2)+mod(W,2)

    end if

end program example