Problem:
 Score : 300 points    Problem Statement There is a rectangle in a coordinate plane. The coordinates of the four vertices are (0,0) , (W,0) , (W,H) , and (0,H) .
You are given a point (x,y) which is within the rectangle or on its border. We will draw a straight line passing through (x,y) to cut the rectangle into two parts. Find the maximum possible area of the part whose area is not larger than that of the other. Additionally, determine if there are multiple ways to cut the rectangle and achieve that maximum.      Constraints  1 \leq W,H \leq 10^9  0\leq x\leq W  0\leq y\leq H  All values in input are integers.         Input Input is given from Standard Input in the following format:  W  H  x  y       Output Print the maximum possible area of the part whose area is not larger than that of the other, followed by 1 if there are multiple ways to cut the rectangle and achieve that maximum, and 0 otherwise.  The area printed will be judged correct when its absolute or relative error is at most 10^{-9} .        Sample Input 1 2 3 1 2      Sample Output 1 3.000000 0  The line x=1 gives the optimal cut, and no other line does.       Sample Input 2 2 2 1 1      Sample Output 2 2.000000 1

Solution (Python):
W,H,x,y = map(int,input().split())

ans = 0
if W % 2 == 0 and W//2==x and H %2 == 0 and H//2==y:
    ans = 1

tate = min((W-x)*H , (x - 0)*H)
yoko = min((H-y)*W , (y - 0)*W)
k = max(tate,yoko)

if (x == W and y == 0) or (x == 0 and y == H) or (x == W and y == H) or (x == 0 and y == 0):
    k = (W*H)/2

if H == W:
    if x == y:
        k = (W*H)/2
    elif y + x == H:
        k = (W*H)/2



k = (W*H)/2
print(k,ans,sep=" ")

Solution (Python):
W, H, x, y = [int(item) for item in input().split()]
S = W * H
ans_m = 0
if (W == 2*x and H==2*y):
  ans_m = 1
print (S/2, ans_m)

Solution (Python):
W,H,x,y = list(map(int, input().split()))

ans = W*H/2

if 2*x==W and 2*y==H:
  print(*(ans, 1))
else:
  print(*(ans,0))

Solution (Python):

W,H,x,y = list(map(int,input().split()))

s = W*H/2

if y*2==H and x*2==W:
    f=1
else:
    f=0

print(s,f)

Solution (Python):
W, H, x, y = map(int, input().split())

if (x == 0 and y == 0) or (x == W and y == H) or (x == W and y == 0) or (x == 0 and y == H):
    print('{:.6f} {}'.format(W * H * 0.5, 0))
elif (W == H and x == y) and (x != W / 2 and y != H / 2):
    print('{:.6f} {}'.format(W * H * 0.5, 0))
elif (W == H and x == y) and (x == W / 2 and y == H / 2):
    print('{:.6f} {}'.format(W * H * 0.5, 1))
elif W == H and (x != W / 2 or y != H / 2):
    print('{:.6f} {}'.format(W * H * 0.5, 0))
else:
    x_list = [H * x, H * (W - x)]
    y_list = [y * W, (H - y) * W]

    x_min = min(x_list)
    y_min = min(y_list)

    if x_min > y_min:
        print('{:.6f} {}'.format(x_min, 0))
    elif x_min < y_min:
        print('{:.6f} {}'.format(y_min, 0))
    elif x_min == y_min:
        print('{:.6f} {}'.format(y_min, 1))

Solution (Python):
W, H, x, y = map(int, input().split())
 
if x == 0 or x == W or y == 0 or y == H:
    print("{:.10f}".format(W*H/2), 0)
else:
    if x == W/2 and y == H/2:
        print("{:.10f}".format(W*H/2), 1)
    else:
        print("{:.10f}".format(W*H/2), 0)

Solution (Python):
whxy = [ float(x) for x in input().split(" ")]
zyusinx = float(whxy[0] / 2)
zyusiny = float(whxy[1] / 2)

result2 = '0'
if zyusinx == whxy[2] and zyusiny == whxy[3]:
    result2 = '1'

square = float((whxy[0]*whxy[1]) / 2 )
print(str(square) + ' ' + result2)

Solution (Python):
w,h,x,y = map(int,input().split())


if (x==0 and y==0) or (x==w and y==0) or (x==0 and y==h)or (x==w and y==h):
    print(h*w*0.5,0)

elif x==0 or y==0 or x==w or y==h:
    print(h*w*0.5,0)
elif h/w == y/x or -h/w == (y-h)/x:
    if x*2 ==w:
        print(w*h*0.5,1)
    else:
        print(w*h*0.5,0)
else:
    
    
    print(h*w*0.5,0)

Solution (Python):
W,H,x,y = [int(x) for x in input().split()]
if x == W/2 and y == H/2:
    print('{:.6f}'.format(W*H/2),1)
else:
    print('{:.6f}'.format(W/2*H),0)

Solution (Python):
w,h,x,y = map(int,input().split())
if x == w/2 and y == h/2:
    print(w*h/2,1)
else:
    print(w*h/2,0)

Solution (Python):

def nyan(f=lambda x: x): return map(f,input().split())
def nyannyan(f=lambda x: x,i=0):
    if i==0: return list(map(f,input().split()))
    l = []
    for j in range(i): l.append(f(input()))
    return l

w,h,x,y = nyan(int)
if x==w/2 and y==h/2:
	k=1
else:
	k=0
print(str((w*h)/2)+" "+str(k))

Solution (Python):
from collections import Counter
from collections import deque
from functools import reduce
from pprint import pprint
import bisect
import copy
import fractions
import itertools
import math
import queue
import random
import sys
import time
sys.setrecursionlimit(10**7)
INF = 10 ** 18
MOD = 10 ** 9 + 7
def LI(): return [int(x) for x in sys.stdin.readline().split()]
def LF(): return [float(x) for x in sys.stdin.readline().split()]
def LS(): return sys.stdin.readline().split()
def MI(): return map(int, sys.stdin.readline().split())
def II(): return int(sys.stdin.readline())
def IS(): return input()
def C(x): return Counter(x)
def GCD_LIST(numbers): return reduce(fractions.gcd, numbers)
def LCM_LIST(numbers): return reduce(LCM, numbers)
def LCM(m, n): return (m * n // fractions.gcd(m, n))


w, h, x, y = MI()
halfw = w/2
halfh = h/2
ans = []

ans.append((w * h) / 2)
if x == halfw and y == halfh:
    ans.append(1)
else:
    ans.append(0)
print(*ans)

Solution (Python):
w, h, x, y = map(int, input().split())
S = w*h
if w/2 == x and h/2 == y:
    print(S/2, 1)
else:
    print(S/2, 0)

Solution (Python):
import sys
import math 
ni = lambda: int(ns())
na = lambda: list(map(int, input().split()))
ns = lambda: input()

W,H,x,y = na()

r = W*H/2
l = 1 if x==W/2 and y==H/2 else 0
print(r,l)

Solution (Python):
W, H, x, y = map(int,input().split())

ans_S = H*W/2

ans = 0

if x == W/2  and y == H/2:
    ans = 1

print('{:.6f}'.format(ans_S), ans)

Solution (Python):
w,h,x,y = map(int,input().split())


num = 0

if w/2 == x and h/2 == y:
  num = 1
print(w*h/2,num)

Solution (Python):
W, H, x, y = map(int, input().split())

square = W * H
square_half = W * H / 2

if W / 2 == x and H / 2 == y:
    print(square_half, 1)
else:
    print(square_half, 0)

Solution (Python):
N = list(map(int, input().split()))
num=0
if N[2]*2==N[0] and N[3]*2==N[1]:
    num=1
print(N[0]*N[1]/2," ",num)

Solution (Python):
W,H,x,y = input().split()
W = int(W)
H = int(H)
x = int(x)
y = int(y)

space = W * H /2.0

if x == W/2.000000 and y == H/2.0:
    print(space,1)
else:
    print(space,0)

Solution (Python):
W,H,x,y = map(int, input().split())
if(W/2==x and H/2==y):
   print(W*H/2, 1)
else:
    print(W*H/2, 0)

Solution (Python):
W, H, x, y = [int(x) for x in input().split()]

num = 0
heaf = W*H/2

if W/2 ==  x and H/2 == y: num = 1
print("{} {}".format(heaf, num))

Solution (Python):
import sys
a=list(map(int,input().split()))
W=a[0]
H=a[1]
x=a[2]
y=a[3]
print(W*H/2)
f1,f2=0,0
if x==W/2:
    f1=1
if y==H/2:
    f2=1
if x==W or y==H:
    print('0')
    sys.exit()
if f1==1 or f2==1:
    if f1==f2:
        print('1')
        sys.exit()
    else:
        print('0')
        sys.exit()
print('0')

Solution (Python):
W, H, x, y = map(int,input().split())

result = float(W * H / 2)

if  W == (x * 2) and H == (y * 2):
  print(result, 1)
else:
  print(result, 0)

Solution (Python):
W, H, x, y = map(int, input().split())
s = (W * H) / 2
if x == W / 2 and y == H / 2:
    print(str(s) + ' 1')
else:
    print(str(s) + ' 0')

Solution (Python):
w,h,x,y = map(int, input().split())
men = float(w * h / 2)
if (2*x == w) and (2*y == h):
    han = 1
else:
    han = 0
print("{} {}".format(men,han))

Solution (Python):
import sys
def input(): return sys.stdin.readline().strip()
 
mi = lambda: map(int, input().split())
 
W, H, x, y = mi()
 
if x == W/2 and y == H/2:
  print('%f 1' % ((W*H)/2))
else:
  print('%f 0' % ((W*H)/2))

Solution (Python):
W, H, x, y = map(float, input().split())
if W/2 == x and H/2 == y:print(round(W*H, 9)/2, 1)
else: print(round(W*H, 9)/2, 0)

Solution (Python):
w,h,x,y = map(int,input().split())
area = w*h/2

if x == w//2 and y == h//2 and w%2 == 0 and h%2 == 0:
    print(area, 1)
else:
    print(area, 0)

Solution (Python):


W,H,x,y = map(int, raw_input().split())
s = W*H
ans = s/2.0
ans2=0
if(W/2.0==x and H/2.0==y):
	ans2 = 1
else:
	ans2 = 0


print str(ans) + " " + str(ans2)

Solution (Python):
w, h, x, y = [int(i) for i in input().split()]

o1 = (w * h) / 2

l = [(x, h / w * x), (x, - h / w * x + h)]
l2 = [(0, 0), (w, 0), (0, h), (w, h)]
if (x, y) in l2:
  o2 = 0
elif (x, y) in l:
  o2 = 1
else:
  o2 = 0
  
print(o1, o2)

Solution (Python):
t = [int(x) for x in input().split()]
w, h, x, y = t[0], t[1], t[2], t[3]

is_double = 0
if (w / 2 == x) and (h / 2 == y):
    is_double = 1
print("{0:.6f}".format(w * h / 2.0), is_double)

Solution (Python):
def li():
    return list(map(int, input().split()))


if __name__ == "__main__":
    [w, h, x, y] = li()
    area = w * h / 2
    multi = w // 2 == x and w % 2 == 0 and h // 2 == y and h % 2 == 0
    if multi:
        print(area, "1")
    else:
        print(area, "0")

Solution (Python):
W, H, x, y = map(float,input().split())
judge = 0
ans = 0

if x == W/2 and y == H/2:
    judge = 1
elif y == (-H*x)/W + H or y == H*x / W:
    judge = 0
elif x == W/2 or y == H/2:
    judge = 0
else:
    judge = 0

ans = W*H / 2

print("{0:.6f}".format(ans), judge)

Solution (Python):
w,h,x,y = map(int,input().split())

t = 0
if (w%2 == 0 and x == w//2) and (h%2 == 0 and y == h//2):
    t = 1
print(w*h/2,t)

Solution (Python):
W, H, x, y = map(int,input().split())

S = W*H/2

if (x,y) == (W/2, H/2):
    ways = 1
else:
    ways = 0

print(S, ways)

Solution (Python):
w, h, x, y = map(int, input().split())
menseki = w * h
res1 = 0
tmp = 0
res2 = 0
if menseki % 2 == 0:
    if x * h <= y * w:
        tmp = x
    else:
        tmp = y

if x == w/2 and y == h/2:
    res2 = 1
else:
    res2 = 0
print(menseki/2, res2)

Solution (Python):
W,H,x,y = map(int,input().split())
ans1 = W*H/2
if x==W/2 and y==H/2:
    ans2 = 1
else:
    ans2 = 0

print("{} {}".format(ans1,ans2))

Solution (Python):

from __future__ import division, print_function

import os
import sys
from __builtin__ import xrange as range
from collections import Counter
from cStringIO import StringIO
from future_builtins import ascii, filter, hex, map, oct, zip
from io import IOBase

import __pypy__


def main():
    W, H, x, y = map(int, input().split())
    _x, _y = W - x, H - y
    print(W * H / 2, int((_x, _y) == (x, y)))




BUFSIZE = 8192


class FastI(IOBase):
    def __init__(self, file):
        self._fd = file.fileno()
        self._buffer = StringIO()
        self.newlines = 0

    def read(self):
        while True:
            b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
            if not b:
                break
            ptr = self.buffer.tell()
            self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr)
        self.newlines = 0
        return self.buffer.read()

    def readline(self):
        while self.newlines == 0:
            b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
            self.newlines = b.count("\n") + (not b)
            ptr = self._buffer.tell()
            self._buffer.seek(0, 2), self._buffer.write(b), self._buffer.seek(ptr)
        self.newlines -= 1
        return self._buffer.readline()


class FastO(IOBase):
    def __init__(self, file):
        self._fd = file.fileno()
        self._buffer = __pypy__.builders.StringBuilder()
        self.write = lambda s: self._buffer.append(s)

    def flush(self):
        os.write(self._fd, self._buffer.build())
        self._buffer = __pypy__.builders.StringBuilder()


def print(*args, **kwargs):
    sep, file = kwargs.pop("sep", " "), kwargs.pop("file", sys.stdout)
    at_start = True
    for x in args:
        if not at_start:
            file.write(sep)
        file.write(str(x))
        at_start = False
    file.write(kwargs.pop("end", "\n"))
    if kwargs.pop("flush", False):
        file.flush()


sys.stdin, sys.stdout = FastI(sys.stdin), FastO(sys.stdout)
input = lambda: sys.stdin.readline().rstrip("\r\n")



if __name__ == "__main__":
    main()

Solution (Python):
W,H,x,y= map(float,input().split())
S = W*H/2.0
if (x == W/2 and y==H/2):
    print("{} {}".format(S,1))
else:
    print("{} {}".format(S,0))

Solution (Python):
def main():
    W, H, x, y = map(int, input().split())
    if (x * 2, y * 2) == (W, H):
        print(W * H / 2, 1, end=' ')
    else:
        print(W * H / 2, 0, end=' ')


main()

Solution (Python):
W, H, x, y = map(int, input().split())

S = W*H
ans1 = S/2
ans2 = 0
if 2*x == W or 2*y == H:
    ans2 = 0
if x == 0 or x == W or y == 0 or y == H:
    ans2 = 0
if 2*x == W and 2*y == H:
    ans2 = 1
print(ans1, ans2)

Solution (Python):

import sys


def solve(W, H, x, y):
    ans = str(H*W/2)
    if x == 0 or y == 0:
        flag = "0"
    else:
        if x == W/2 and y == H/2:
            flag = "1"
        else:
            flag = "0"
    print(ans + " " + flag)

    return



def main():
    def iterate_tokens():
        for line in sys.stdin:
            for word in line.split():
                yield word

    tokens = iterate_tokens()
    W = int(next(tokens))  
    H = int(next(tokens))  
    x = int(next(tokens))  
    y = int(next(tokens))  
    solve(W, H, x, y)


if __name__ == "__main__":
    main()

Solution (Python):
import sys

W, H, x, y  = list(map(int, input().split()))


gx = W/2.0
gy = H/2.0

if gx == x and gy == y:
    hoge = 1
else:
    hoge = 0

print((W*H)/2, hoge)

Solution (Python):
W, H, x, y = map(int, input().split())
answer = float(W) * float(H) / 2.0
solution = -1
if(float(x) == float(W) / 2.0 and float(y) == float(H) / 2.0):
    solution = 1
else:
    solution = 0
print(answer,solution)

Solution (Python):
w, h, x, y = list(map(int, input().split()))
multi = 0

if x == w / 2 and y == h / 2:
    multi = 1

print (format(w * h / 2, '.6f'), multi)

Solution (Python):
W,H,x,y = map(float,input().split(" "))
ans = (W * H) / 2
flag = 0
if (W / 2) == x and (H/2) == y:
    flag = 1
else:
    flag = 0
print(str(ans) + " " + str(flag))

Solution (Python):
W, H, x, y = map(int, input().split())
S = W * H
isMulti = 0

max = float(S / 2)

if W/2 == x and H/2 == y:
    isMulti = 1

print('{:.6f}'.format(max), isMulti)

Solution (Python):
w, h, x, y = [int(s) for s in input().split(" ")]

a = w * h

print("%lf %d" % (a * 0.5, int(divmod(w, 2) == (x, 0) and divmod(h, 2) == (y, 0))))

Solution (Python):
import bisect
from operator import itemgetter
import math
import collections
import functools
import itertools
import numpy as np
import sys
MAX_INT = int(10e10)
MIN_INT = -MAX_INT
mod = 1000000007
sys.setrecursionlimit(1000000)
def IL(): return list(map(int,input().split()))
def SL(): return input().split()
def I(): return int(sys.stdin.readline())
def S(): return input()


W,H,x,y = IL()

cnt = 0
if x*2 == W and y*2 == H:
  cnt = 1

print((H*W)/2,cnt)

Solution (Python):
W, H, x, y = map(int,input().split())

a = W*H/2
b = 0

if W/2 == x and H/2 == y:
    b = 1

print(a,b)

Solution (Python):
W, H, x ,y =  map(int,input().split())
half_area = float(W*H)/2.0
if (W % 2 == 0) and (H % 2 == 0) and (x == int(float(W*0.5)) ) and (y == int(float(H*0.5)) ):
  num = 1
else:
  num = 0
print('{:.6f}'.format(half_area)+" "+ str(num))

Solution (Python):
w, h, x, y = map(int,input().split())
s = (w*h)/2
if x == w/2 and y == h/2:
  print("{0:.6f}".format(s), 1)
else:
  print("{0:.6f}".format(s), 0)

Solution (Python):
w,h,x,y = map(int,input().split())

a = min(x,w-x)
s = h*a

b = min(y, h-y)
t = w*b

result = 0

if x == w/2 and y == h/2:
    result = 1

print(h*w/2,result)

Solution (Python):
W, H, x, y = map(int, input().split())
if x == W / 2 and y == H / 2:
    print(W * H / 2, 1)
else:
    print(W * H / 2, 0)

Solution (Python):
W,H,x,y = map(int,input().split())
a = x*H
b = (W-x)*H
c = (H-y)*W
d = H*W
if x == W/2 and y == H/2:
  print(a,1)
else:
  print(H*W/2,0)

Solution (Python):
w, h, x, y = map(float, input().split())

s = w * h / 2

m = 0
if x == w / 2 and y == h / 2:
    m = 1

print("%.6f %d" % (s, m))

Solution (Python):
w,h,x,y=map(int,input().split())
ans1=w*h/2
if w/2==x and  h/2==y:
 ans2=1
else:
 ans2=0
print(ans1,ans2)

Solution (Python):
w, h, x, y = list(map(int, input().split()))
diffx = x-w/2
diffy = y-h/2
if diffx >= 0:
  signx = 1
else:
  signx =-1
x2 = signx*diffx + w/2

if diffy >= 0:
  signy = 1
else:
  signy =-1
y2 = signy*diffy+ h/2

if diffx==0 and diffy==0:
  print("{} {}".format(w*h/2, 1))
else:
  print("{} {}".format(w*h/2, 0))

Solution (Python):
w,h,x,y = map(int, input().split())
if (float(x),float(y)) == (w/2,h/2):
  print(w*h/2,1)
else:
  print(w*h/2,0)

Solution (Python):


W, H, x, y = map(float, input().split())

if x/W == 0.5 and y/H == 0.5:   
	print(W*H/2,"1")
else:
	print(W*H/2,"0")

Solution (Python):
W , H , x , y = map(int,input().split())
if x == 0 or x == W:
	x_on_line = True
else:
	x_on_line = False
if y == 0 or y == H:
	y_on_line = True
else:
	y_on_line = False


if x_on_line or y_on_line:
	pattern = 0
	S = W * H / 2
else:
	if (W / 2) == float(x):
		x_half_point = True
	else:
		x_half_point = False
	if (H / 2) == float(y):
		y_half_point = True
	else:
		y_half_point = False
	if x_half_point and y_half_point:
		pattern = 1
		S = W * H / 2
	elif x_half_point or y_half_point:
		pattern = 0
		S = W * H / 2	
	else:
		S = W * H / 2
		pattern = 0
print(S,pattern)

Solution (Python):
w,h,x,y=map(int,input().split())

if w==h and x==y and x==w/2:
    s=1


elif x==w/2 and y==h/2:
    s=1
else:
    s=0


S=w*h/2

print(str(S)+' '+str(s))

Solution (Python):
import math,string,itertools,fractions,heapq,collections,re,array,bisect,sys,random,time

sys.setrecursionlimit(10**7)
inf=10**20
mod=10**9+7

def LI(): return list(map(int,input().split()))
def I(): return int(input())
def LS(): return input().split()
def S(): return input()

def main():
  w,h,x,y=LI()

  if w/2==x and h/2==y:
    print(w*h/2,1)
  else:
    print(w*h/2,0)

main()

Solution (Python):
w, h, x, y = map(int, input().split())

if ((w/2) == x) and ((h/2) == y):
    ans = 1
else:
    ans = 0

print(str(w*h / 2) + " " + str(ans))

Solution (Python):
import sys

w,h,x,y = [ int(x) for x in sys.stdin.readline().split() ]
wh = w / 2
hh = h / 2

if abs(wh-x)<0.01 and abs(hh-y)<0.01: flag= 1
else: flag= 0

print( "{:>.9f} {:>d}".format( (w*h/2),flag ) )

Solution (Python):
w,h,x,y=map(int,input().split())
if x==w/2 and y==h/2:
  print(w*h/2,1)
else:
  print(w*h/2,0)

Solution (Python):
w, h, x, y = map(int, input().split())

pattern = 0
if w/2 == x and h/2 == y:
    pattern = 1

print("{} {}".format(w*h/2, pattern))

Solution (Python):
w,h,x,y=map(int,input().split())
if x==w/2 and y==h/2:
    ans1=w*h/2
    ans2=1
else:
    ans1=w*h/2
    ans2=0
print(ans1,ans2)

Solution (Python):
W,H,x,y = map(int,input().split())

if x == W and y == H:
	print(W*H/2,end=" ")
	print(0)
	
elif x == W and y == 0:
	print(W*H/2,end=" ")
	print(0)

elif x == 0 and y == H:
	print(W*H/2,end=" ")
	print(0)
	
elif x == 0 and y == 0:
	print(W*H/2,end=" ")
	print(0)

elif x == W/2 and y == H/2:
	print(W*H/2,end=" ")
	print(1)
	
elif x == W/2:
	print(W*H/2,end=" ")
	print(0)
	
elif y == H/2:
	print(W*H/2,end=" ")
	print(0)

else:
	print(W*H/2,end=" ")
	print(0)

Solution (Python):
W, H, x, y = map(int, input().split())

gx = W / 2
gy = H / 2

is_multi = 1 if (x, y) == (gx, gy) else 0

print(str(W * H / 2) + " " + str(is_multi))

Solution (Python):
W, H, x, y = map(int, input().split())

ans = '{} {}'.format(
    W * H / 2,
    1 if 2 * x == W and 2 * y == H else
    0
)

print(ans)

Solution (Python):
W,H,x,y = map(int,input().split())

if x == 0 or x == W or y == 0 or y == H:
    menseki = W * H / 2
    print("{} 0".format(menseki))
elif x == W/2 and y == H/2:
    menseki = W * H / 2
    print("{} 1".format(menseki))
elif x == W/2 or y == H/2:
    menseki = W * H / 2
    print("{} 0".format(menseki))
else:
    menseki = W * H / 2
    print("{} 0".format(menseki))

Solution (Python):
w, h, x, y = map(int, input().split())

rect = w * h

cx = w / 2
cy = h / 2

if x == cx:
    s = x * h
elif y == cy:
    s = y * w
else:
    a = (x - cx) / (y - cy)
    if -1 < a < 1:
        s = w * cy
    else:
        s = h * cx

if cx == x and cy == y:
    print(s, 1)
else:
    print(s, 0)

Solution (Python):
W,H,x,y = map(int,input().split())
max=W*H/2
xx=W/2
yy=H/2
if xx==x and yy==y:
  check=1
else:
  check=0
  
print(max,check)

Solution (Python):
w, h, x, y = map(int, input().split())
area = w * h
ans = area / 2
ways = 0
if w & 1 == 0 and w // 2 == x and h & 1 == 0 and h // 2 == y:
    ways = 1
print(ans, ways)

Solution (Python):
w,h,x,y = map(int,input().split())
a = 0
if x == w/2 and y == h/2:
  a = 1

s = w*h/2
print(s,a)

Solution (Python):
W, H, x, y = map(int, input().split())

if W / 2 == x and H / 2 == y:
    flag = '1'
    s = (W / 2) * H

elif W / 2 == x and H / 2 != y:
    flag = '0'
    s = (W / 2) * H

elif W / 2 != x and H / 2 == y:
    flag = '0'
    s = W * (H / 2)

elif W / 2 != x and H / 2 != y:
    flag = '0'
    s = W * H / 2

print('{} {}'.format(s, flag))

Solution (Python):
import sys
input = sys.stdin.readline
W,H,x,y = map(int,input().split())

ans = W*H /2
	
if x == W/2 and y == H/2:
    a = 1
else:
    a =0
print(ans, a)

Solution (Python):
def solve(W, H, x, y):
    if W % 2 == 0 and H % 2 == 0:
        if x == W//2 and y == H//2:
            return 1
    return 0

def main():
    W, H, x, y = [int(x) for x in input().split()]
    print((W*H)/2, solve(W, H, x, y))

    pass
main()

Solution (Python):
W,H,x,y=map(int,input().split())

M=W*H

if x*2==W and y*2==H:
    print(M/2,1)
else:
    print(M/2,0)

Solution (Python):
w,h,x,y=map(int,input().split())
print(w*h/2)
print('1') if x==w/2 and y==h/2 else print('0')

Solution (Python):
w, h, x, y = (int(i) for i in input().split())


if x==0 or x==w:
    kadoa=1
else:
    kadoa=0

if y==0 or y==h:
    kadob=1
else:
    kadob=0

first=x*h
second=(w-x)*h

mazu=min(first, second)
 
first=y*w
second=(h-y)*w
 
tugi=min(first, second)

chisai=min(mazu,tugi)

if x==(w/2) and y==(h/2):
    print(w*h/2, 1)
else:
    print(w*h/2, 0)

Solution (Python):
W,H,x,y = map(int,input().split())
ans1 = W*H/2
ans2 = 1 if W/2==x and H/2==y else 0
print(ans1,ans2)

Solution (Python):
w,h,x,y=map(int,input().split())
ans=0
ans=float(w*h/2)
ways=0
if 2*x==w and 2*y==h:
  ways=1
else:
  ways=0
print(str(ans)+' '+str(ways))

Solution (Python):
w, h, x, y = (int(i) for i in input().split())
print(w * h / 2)
if x * 2 == w and y * 2 == h:
    print(1)
else:
    print(0)

Solution (Python):
W, H, x, y = map(int, input().split())

if x == W/2 and y == H/2:
    print((W*H)/2, 1)
else:
    print((W*H)/2, 0)

Solution (Python):
W,H,a,b = map(int, input().split())

if W == 2 * a and H == 2 * b:
    print((W * H) / 2 ,1)

else:
    print((W * H) / 2 ,0)

Solution (Python):
W ,H ,x ,y = map(int ,input().split())
print(W * H / 2.0)
if x == W / 2.0 and y == H / 2.0:
    print(1)
else:
    print(0)

Solution (Python):
w,h,x,y=map(int, input().split())

if w/2==x and h/2==y:
  result='1'
else:
  result='0'

s=w*h

print(str("{0:.9f}".format(s/2))+' '+result)

Solution (Python):
w,h,x,y=map(int,input().split())

smax=w*h/2
hukusuu=0
if (x==w/2) and (y==h/2):
    hukusuu=1

print(smax,hukusuu)

Solution (Python):
W, H, x, y = (int(x) for x in input().split())

if x == W / 2 and y == H / 2:
  print(str(W * H / 2) + " " + str(1))
else:
  print(str(W * H / 2) + " " + str(0))

Solution (Python):
W, H, x, y = map(int, input().split())

sq = (W * H) / 2

someFlg = 0

if x == W / 2 and y == H / 2:
    someFlg = 1

print(str(sq) + " " + str(someFlg))

Solution (Python):
W,H,x,y=map(int,input().split())
flag=0
X=min([W-x,x])
Y=min([H-y,y])
if x==W/2 and y==H/2:
    print(W*H/2,1)
else:
    print(W*H/2,0)

Solution (Python):
W, H, x, y = map(int, input().split())
center_x, center_y = W / 2, H / 2
ans = []

if x == center_x and y == center_y:
    ans.append(W * H / 2)
    ans.append(1)
elif x == center_x or y == center_y:
    ans.append(W * H / 2)
    ans.append(0)
else:
    a = (center_y - y) / (center_x - x)
    b = center_y - a * center_x

    if b == 0:
        s1 = 0
    else:
        s1 = - b / a
    s2 = (H - b) / a
    s3 = b
    s4 = a * W + b

    area = 0
    if 0 <= s1 <= W:
        area1 = (s1 + s2) * H / 2
        area2 = (2*H - s1 - s2) * H / 2
        area = min(area1, area2)
    else:
        area1 = (s3 + s4) * W / 2
        area2 = (2*W - s3 - s4) * W / 2
        area = min(area1, area2)
        
    ans.append(area)
    ans.append(0)
print("{:.6f} {:d}".format(*ans))

Solution (Python):
w, h, x, y = map(int, input().split())
sq = 0
nearX = x - (w / 2)
nearY = y - (h / 2)
flag = False
if (x == 0 and y == 0) or (x == w and y == h) or (x == 0 and y == h) or (x == w and y == 0):
    flag = True

if flag:
    sq = (w*h)/2
    print(str(sq) + ' ' + '0')
    
elif nearY < nearX:
    sq = w * (h / 2)
    print(str(sq) + ' ' + '0')
elif nearX < nearY:
    sq = h * (w / 2)
    print(str(sq) + ' ' + '0')
else:
    sq = h * (w / 2)
    print(str(sq) + ' ' + '1')

Solution (Python):
w,h,x,y = map(int,input().split())
a=(w*h)/2
if (w%2==0 and w//2==x ) and (h%2==0 and h//2 == y):
    print(a,1)
else:
    print(a,0)

Solution (Python):
w,h,x,y = map(int,input().split())
print(w*h/2, end = " ")
if x == w/2 and y == h/2:
  print(1)
else:
  print(0)

Solution (Python):
w,h,x,y=map(int,input().split())
flag=0

print(float((w*h)/2),end=' ')

if x==w/2 and y==h/2:
    print(1)
else:
    print(0)

Solution (Python):
def c():
    W, H, x, y = map(int, input().split())

    
    
    if 2*x == W and 2*y == H:
        print(W*H/2.0, 1)
    else:
        print(W*H/2.0, 0)

c()

Solution (Python):
W,H,x,y = map(int,input().split())
multiplesolution = 0
if x==W/2 and y == H/2:
    multiplesolution = 1
print("%f %d"%(W*H/2,multiplesolution))

Solution (Python):
W, H, x, y = map(int, input().split())

print (W * H /2, end = ' ')
if W/2 == x and H/2 == y:
    print (1)
else:
    print (0)

Solution (Python):

w, h, x, y = [int(i) for i in input().split()]
ans = 0
if x * 2 == w and y * 2 == h:
    ans = 1
print(w * h / 2, ans)

Solution (Python):
W,H,x,y = map(int,input().split())

if 2 * x == W and 2 * y == H:
    print(W*H/2,1)    
else:
    print(W*H/2,0)

Solution (Python):
W, H, x, y = map(int, input().split())
ans = W*H/2
if (x == W/2 and y == H/2):
        print(str(ans) + ' ' + str(1))
else:
        print(str(ans) + ' ' + str(0))

Solution (Python):
W, H, x, y = map(int, input().split())

if W % 2 == 0 and H % 2 == 0 and x == W // 2 and y == H // 2:
    is_mullt_ans = 1
else:
    is_mullt_ans = 0

print(W * H / 2, is_mullt_ans)

Solution (Python):
W, H, x, y = map(int, input().split())
if x == W/2.0 and y == H/2.0:
   print("%f %d" % (W*H/2.0, 1))
elif x == W/2.0 or y == H/2.0 or y == 1.0*H/W*x or y == H-1.0*H/W*x or y == 0 or y == H or x == 0 or x == W:
  print("%f %d" % (W*H/2.0, 0))
else:
  print("%f %d" % (W*H/2.0, 0))

Solution (Python):

w,h,x,y=map(int,input().split())
if x==w/2 and y==h/2:
    print("{:.6f}".format(w*h/2),1)
else:
    print("{:.6f}".format(w*h/2),0)

Solution (Python):
w, h, x, y = map(int, input().split())
print(w*h/2, end=" ")
print(1 if w/2==x and h/2==y else 0)

Solution (Python):
w,h,x,y=map(int,input().split())
print(w*h/2,1 if x * 2 == w and y * 2 == h else 0)

Solution (Python):

import sys


def solve(W: int, H: int, x: int, y: int):
    many = 0
    if x*2 == W and y*2 == H:
        many = 1
    print(W*H/2,many)



def main():
    def iterate_tokens():
        for line in sys.stdin:
            for word in line.split():
                yield word
    tokens = iterate_tokens()
    W = int(next(tokens))  
    H = int(next(tokens))  
    x = int(next(tokens))  
    y = int(next(tokens))  
    solve(W, H, x, y)

if __name__ == '__main__':
    main()

Solution (Python):
W,H,x,y = map(int,input().split())

op = 1 if W/2==x and H/2==y else 0
print(W*H/2,op)

Solution (Python):
W, H, x, y = list(map(int, input().split()))

ans = W*H/2

flag = 0


if W/2 == x and H/2 == y:
    flag = 1


print(ans,flag)

Solution (Python):

import sys
def input(): return sys.stdin.readline().rstrip()
def mi(): return map(int, input().split())


W, H, x, y = mi()

ans1 = (W*H)/2

ans2 = 1 if W%2==0 and H%2==0 and x==W//2 and y==H//2 else 0

print(ans1, ans2)

Solution (Python):
w,h,x,y = map(int, raw_input().split())

if (w-x)==x and (h-y)==y:
    print float(w*h)/2,1
else:
    print float(w*h)/2,0

Solution (Python):
w, h, x, y = list(map(int, input().split()))
if w / 2 == x and h / 2 == y:
    print(w * h / 2, 1)
else:
    print(w * h / 2, 0)

Solution (Python):
w, h, x, y = map(int, input().split())

max = w * h / 2
if (x == w/2) and (y == h/2):
  ans = 1
else:
  ans = 0
  
print(max, ans)

Solution (Python):
W, H, x, y = [int(e) for e in input().split()]
if 2*x == W and 2*y == H:
    print(W*H / 2, 1)
else:
    print(W*H / 2, 0)

Solution (Python):
W, H, x, y = map(int, input().split())

import fractions

if x * 2 == W or y * 2 == H:
	if x * 2 == W and y * 2 == H:
		c = 1
	else:
		c = 0
else:
	x1 = fractions.Fraction(H * x - y * W, H - 2 * y)
	y1 = fractions.Fraction(W * y - x * H, W - 2 * x)
	
	if 0 <= x1 <= W and 0 <= y1 <= H:
		if (x1 == 0 or x1 == W) and (y1 == 0 or y1 == H):
			c = 0
		else:
			c = 1
	else:
		c = 0
	
	
	

print(W * H / 2, c)

Solution (Python):
w, h, x, y = map(int, input().split())

s = w * h / 2.0
if w == (x * 2.0) and h == (y * 2.0):
    c = 1
else:
    c = 0
print(s, c)

Solution (Python):
W, H, x, y = map(int, input().split())
if x * 2 == W and y * 2 == H:
    ans = 1
else:
    ans = 0
print(W * H / 2, ans)

Solution (Python):

W, H, x, y = map(int, input().split())


if x == W/2 and y == H/2:
  menseki = W*H/2
  print(menseki,1)
else:
  menseki = W*H/2
  print(menseki,0)

Solution (Python):
w,h,x,y=[int(i) for i in input().split()]
if w/2==x and h/2==y:
  print(w*h/2,1)
else:
  print(w*h/2,0)

Solution (Python):
W, H, x, y = map( int, input().split())
if x*2 == W and y*2 == H:
    print(W*H/2, 1)
else:
    print(W*H/2, 0)

Solution (Python):
W, H, x, y = map(int, input().split())
ans1 = W * H / 2
ans2 = 0

if x == W / 2 and y == H /2:
	ans2 = 1
else:
	ans2 = 0

print(ans1, ans2)

Solution (Python):
w, h, x, y = map(int, input().split())
if w/2 == x and h/2 == y:
    print(w*h/2, 1)
else:
    print(w*h/2, 0)

Solution (Python):
if __name__ == "__main__":
    w, h, x, y = map(int, input().split())
    if x == w / 2 and y == h / 2:
        hukusuu = 1
    else:
        hukusuu = 0

    print(w * h / 2, hukusuu)

Solution (Python):
W, H, x, y = map(int, input().split())
menseki = float(W) * float(H) / 2

if W == x * 2 and H == y * 2:
    half = 1
else:
    half = 0

print(menseki, half)

Solution (Python):
w,h,x,y=map(int,input().split())
if(x==w/2 and y==h/2):
    print('{0} 1'.format(w*h/2))
if(x!=w/2 or y!=h/2):
    print('{0} 0'.format(w*h/2))

Solution (Python):
w,h,x,y=map(int,input().split())
if 2*x==w and 2*y==h:
    print(0.5*w*h,'1')
else:
    print(0.5*w*h,'0')

Solution (Python):

w,h,x,y = map(int,input().split())
if w/2 == x and h/2 == y:
    print(w*h/2,1)
else:
    print(w*h/2,0)

Solution (Python):
W,H,x,y = map(int,input().split())
x = min(W-x,x)
y = min(H-y,y)
ans = 0
if 2*x == W and 2*y == H:
    ans = 1
print('{} {}'.format(W*H/2,ans))