program main
  implicit none
  integer :: x, y, w, h
  double precision :: area
  integer :: flag

  read(*,*) w, h, x, y
  area = dble(w)*dble(h)/2.0d0


  if (x+x == w .and. y+y == h) then
    flag = 1
  else
    flag = 0
  endif


  write(*,*) area, flag

end program main
