peterverebics/CodeNet_Python_118 huggingface dataset:
n, x =map(int,input().split())
l = list(map(int,input().split()))
d = 0
for i in range(n):
    if d > x:
        print(i)
        exit()
    d += l[i]
print(n)
n,x = map(int,input().split())
l = list(map(int,input().split()))
d = 0
cnt = 0
for i in range(n):
	cnt += 1
	d += l[i]
	if x < d:
		print(cnt)
		exit()
N, X = map(int,input().split())
lst = list(map(int,input().split()))

cnt = 0
now = 0
for i in range(N):
    l = now + lst[i]
    cnt += 1
    now = l
    if now > X:
        break
print(cnt)
n, x = map(int, input().split())
l = list(map(int, input().split()))

d = 0
for i in range(n):
    if d > x:
        print(i)
        exit(0)
    d += l[i]
print(n + 1)
import sys

N, X = map(int, sys.stdin.readline().split())
L = list(map(int, sys.stdin.readline().split()))

ans = 0
for i, l in enumerate(L):
    ans += l
    if ans > X:
        print(i+1)
        break
else:
    print(N-1)
N, X = map(int, input().split())
L=list(map(int, input().split()))

D=0
count=1
while D<=X and count<=N:
   D=D+L[count-1]
   count+=1

print(min(N+1, count-1))
N,X=map(int,input().split())
L=list(map(int,input().split()))

count=0
dist=0

i=0
while dist<=X and count<=N:
    count+=1
    dist+=L[i]
    #print(dist)

print(count)
def q2():
    N, X = (int(i) for i in input().split())
    l = [int(i) for i in input().split()]
    L = [0]
    for i in range(N):
        L.append(l[i])

    sum_L = L[0]
    if sum_L >= X:
        print(1)
        return

    ans = 1
    for i in range(1, N):
        sum_L += L[i]
        if sum_L <= X:
            ans += 1

    print(ans)


if __name__ == '__main__':
    q2()
n,x = map(int,input().split())
l = list(map(int,input().split()))
count = 0
sum = 0
for i in range(n):
    if sum  <= x:
        count += 1
    sum += l[i]
print(count)
n, x = map(int, input().split())
num = list(map(int, input().split()))
d = 0
cnt = 0
for i in range(n):
  if x == 0:
    print(0)
  d += num[i]
  cnt += 1
  if d > x:
    print(cnt)
    exit()
n, x = map(int,input().split())
l = list(map(int, input().split()))
s, count = 0, 0
for i in l:
    if s>x:
        break
    else:
        s += i
        count += 1
print(count)
n, x = map(int, input().split())
l = list(map(int, input().split()))
res = 0
for i in range(n):
    res += l[i]
    if x < res:
        break
print(i+1)
n,x = map(int,input().split())
b = list(map(int,input().split()))
cnt = 0
ans = 0
for i in b:
  if cnt <= x:
    ans += 1
    cnt += i

 
print(ans)
N, X = map(int, input().split())
L = input().split()
L = [int(i) for i in L]

d =0
count=1
for i in range(N):
    d = d+L[i]
    if d > X:
        print(count)
        break
    count+=1
n,x = map(int ,input().split())
l = list(map(int ,input().split()))
old_d = 0
count = 1
for i in range(1 ,n+1):
    new_d =old_d +l[i-1]
    old_d = new_d
    print(old_d)
    if new_d <= x:
        count +=1
print(count)
N,X= map(int,input().split())
li = list(map(int,input().split()))
count = 0
for i in range(len(li)):
    if li[i]<=X:
        count +=1
    else:
        pass
print(count)
n,x=map(int,input().split())
l=list(map(int,input().split()))
z=0
ans=0
i=0
for i in range(n):
  if z>x:
    break
  else:
    ans+=1
    z+=l[i]
    
print(ans)
n,x= input().split()
b_list= list(map(int, input().split()))
temp = 0
counter = 0
for i in b_list:
    if (temp<=int(x)):
        counter +=1
    temp += i

print(counter)
n,x=map(int,input().split())
l=list(map(int,input().split()))
fly=0
for i in range(n):
  fly+=l[i]
  if fly>x:
    print(i+1)
    exit()
n,x=map(int,input().split())
a=list(map(int,input().split()))
cnt=1
now=0
if sum(a)==x:
    print(n+1)
    exit()
for i in a:
    now+=i
    if now>x:
        print(cnt)
        exit()
    cnt+=1
n, x = map(int,input().split())
l = list(map(int, input().split()))
cnt = 0
d = [0]
for i in range(1, n+1):
    d.append(d[i-1] + l[-1])
for i in range(n):
    if d[i] <= x:
        cnt +=1
print(cnt)
N,X = map(int,input().split())
l = list(map(int,input().split()))

sum=0
for i in range(N):
    if sum>X:
        print(i)
        exit()
    sum += l[i]
n,x = map(int,input().split())
l = list(map(int,input().split()))
d = [0]
for i in range(n):
  d.append(d[i]+l[i])
ans = 0
for i in range(n):
  if d[i] <= x:
    ans += 1
print(ans)
"""
author : halo2halo
date : 9, Jan, 2020
"""

import sys

# import numpy as np
import itertools

read = sys.stdin.buffer.read
readline = sys.stdin.buffer.readline
readlines = sys.stdin.buffer.readlines
sys.setrecursionlimit(10 ** 7)

N, X, *L = map(int, read().split())

Lcum = itertools.accumulate(L)

answer = sum(i < X for i in Lcum)
print(answer + 1)
n, x = map(int, input().split())
l = list(map(int, input().split()))
dim1 = 0
for i in range(n):
    dim1 = dim1 + l[i]
    if dim1 > x:
        print(i+1)
        break
def mapt(fn, *args):
    return tuple(map(fn, *args))


def Input():
    return mapt(int, input().split(" "))


def main():
    n, x = Input()
    l = Input()
    d = list(range(n+1))
    ans = 0

    for i in range(1, n+1):
        d[i] = d[i-1] + l[i-1]

    for i in d:
        if i <= x: ans += 1

    print(ans)
n, x = map(int,input().split())
l = list(map(int, input().split()))
s, count = 0, 0
for i in l:
    if s>x:
        print(count);        break
    else:
        s += i;        count += 1
else:
    print(count+1)
N,L=map(int,input().split())
A=list(map(int,input().split()))
hane=0
count=0
for i in range(N):
    count+=A[i]
    hane+=1
    if count>L:
        break

print(hane)
def main():
    n,x = map(int, input().split())
    num_list = list(map(int, input().split()))

    count = 0
    sum = 0

    while(sum <= x):
        if count >= len(num_list):
            break
        sum += num_list[count]
        count += 1

    print(count)

if __name__ == '__main__':
    main()
N, val= list(map(int,input().split()))
list = list(map(int,input().split()))
d=0
l=[]
for i in list:
  ans=d+i
  l.append(ans)
count=0
for num in l:
  if num<=val:
    count=count+1
print(count)
N,X = map(int,input().split())
L = list(map(int,input().split()))
D = [0]*(N+1)
x = 0
for i in range(1,N+1):
  D[i] = D[i-1]+L[i-1]
while D[x] <= X and x < N:
  x += 1
print(x)
n, x = [int(i) for i in input().split()]
l = [int(i) for i in input().split()]
a = 0
b = 0
for i in range(n):
  a += l[i]
  b += 1
  if a > x:
    break
    
print(b)
n, x = list(map(int, input().split()))
l = list(map(int, input().split()))
c, p = 0, 0
while True:
    if c == n - 1:
        break
    if p + l[c] <= x:
        p += l[c]
        c += 1
    else:
        break
print(c + 1)
n,y=map(int,input().split())
lst=list(map(int,input().split())) 
lst=[0]+lst
cnt=0 
sum_lst=0 
for i in range(n+1): 
	sum_lst+=lst[i]
	if sum_lst<=y:
		cnt+=1
print(cnt-1)
N,X=list(map(int, input().split()))
L=list(map(int, input().split()))
c=1
for i in range(N):
  if L[i]<=X:
    c+=1
print(c)
a,b=map(int,input().split())
l=list(map(int,input().split()))
c=0
d=1
for i in range(a):
  c+=l[i]

  if c>b:
    print(d)
    break
  d+=1
n,x = map(int,input().split())
l = list(map(int,input().split()))
ans = 0
d = 0
while d<=x and ans<n:
    d += l[ans]
    ans += 1
print(ans)
from sys import stdin, setrecursionlimit


def main():
    input = stdin.buffer.readline
    n, x = map(int, input().split())
    l = list(map(int, input().split()))

    d = 0
    for i in range(n):
        d += l[i]
        if d > x:
            print(i + 1)
            exit()


if __name__ == "__main__":
    setrecursionlimit(10000)
    main()
n, x = map(int, input().split())
l = list(map(int, input().split()))
cnt = 1
d = 0
for i in range(n):
    d += l[i]
    if d >= x:
        break
    cnt += 1
print(cnt)
n, x = map(int, input().split())
l = list(map(int, input().split()))
d = 0
e = 1
for i in l:
  
  if d + i <= x:
    e += 1
    d = d + i
print(e)
n, x = map(int, input().split())

l_list = list(map(int, input().split()))

tmp = 0
for i in range(100):
    tmp += l_list[i]
    if tmp > x:
        break

print(i+1)
n, x = map(int, input().split())
L = list(map(int, input().split()))

point = 0
ans = 0
for l in L:
    point += l
    ans += 1
    if point > x:
        break
print(ans)
N, X = map(int, input().split())
L = list(map(int, input().split()))
c = 0
d = 0
for i in range(N):
  c += 1
  d += L[i]
  if d > X:
    break
print(c)
N, X = list(map(lambda a: int(a), input().split(" ")))
L = list(map(lambda b: int(b), input().split(" ")))

i = 0
s = 0
while(s <= X and i < len(L)):
  s += L[i]
  i += 1

print(i)
import sys
input = lambda: sys.stdin.readline().rstrip()
input_nums = lambda: list(map(int, input().split()))

def main():
    N, X = input_nums()
    L = input_nums()
    s = 0
    cnt = 0
    for i in range(N):
        if s <= X:
            cnt += 1
        s += L[i]
    print(cnt)

if __name__ == '__main__':
    main()
n, x = map(int, input().split())
print("n:%d" %n)
print("x:%d" %x)
l = list(map(int, input().split()))
sum = 0
b = 1;
for i in range(n):
	sum = sum + l[i]
	if(sum > x):
		print(b)
		break
	else:
		if(i == n-1):
			print(n+1)
			break
		else:
			b=b+1
N, X = map(int, input().split())
L = list(map(int, input().split()))
d = 0
for i in range(N):
  d += L[i]
  if X < d:
    print(i + 1)
    break
  else:
    print(N + 1)
abc = [int(e) for e in input().split()]
length = [int(e) for e in input().split()]

N = abc[0]
X = abc[1]

total_length = 0
count = 1

for i in range(len(length)):
    if total_length > X:
        count = count - 1
        break
    total_length = total_length + length[i]
    count = count + 1


if count > (N+1):
    print(N+1)
else:
    print(count)
n,x = map(int, input().split())
l = list(map(int, input().split()))
now=0
ans=0
for tmp in l:
        ans+=1
        now+=tmp
        if now>x:
                break
print(ans)
N,X=map(int,input().split())
L=list(map(int,input().split()))
mem=0; ans=0
for i in L:
    if mem<=X: ans+=1
    mem+=i
print(ans)
icase=0
if icase==0:
    n,x=map(int,input().split())
    l=list(map(int,input().split()))
    d=0
    for i in range(n):
        d=d+l[i]
        if d>x:
            print(i+1)
            break
    if d<=x:
        print(n)
N, X = map(int, input().split())
l = [0] + list(map(int, input().split()))

d = [0] * (N+1)
for i in range(1, N+1):
    if d[i-1] > X:
        break
    d[i] = d[i-1] + l[i]
    cnt = i
print(cnt)
n,x=map(int,input().split())
L=[int(_) for _ in input().split()]
S_L=[0]
count=1
for i in range(n):
    S_L.append(S_L[-1]+L[i])
    if S_L[-1]<=x:
        count+=1
    else:
        print(count)
        break
n, x = list(map(int, input().split()))
l = list(map(int, input().split()))
c = 0
total = 0
f = 0
for i in l:
  total += i
  if total > x:
    print(c+1)
    f = 1
    break
  c += 1
if f == 0:
  print(c)
n,x = map(int,input().split())
l = list(map(int,input().split()))

sum = 0

for k in range(n):
        sum += l[k]
        if sum > x:
            print(k+1)
            break
import sys
input = sys.stdin.readline
N, X = map(int, input().split())
a = list(map(int, input().split()))
cs = [0] * (N + 1)
for i in range(N): cs[i + 1] = cs[i] + a[i]
res = 0
for i in range(N + 1):
  if cs[i] > X:
    res = i
    break
print(res)
n, x = map(int, input().split())
l = list(map(int, input().split()))
d = 0
c = 0
for i in range(1, n + 1):
    if d <= x:
        c += 1
    d += l[i - 1]
print(c)
n,x=map(int,input().split())
l=list(map(int,input().split()))
d=0
a=0
for i in range(n-1):
    a+=1
    i+=1
    d+=l[i]
    if d>x:
        break

if d==x:
    a+=1

print(a)
n, x = map(int, input().split())
l = list(map(int, input().split()))
a = 1
d = 0
for i in range(n):
    d = d + l[i]
    if d >= x:
        if d == x:
            a += 1
        print(a)
        exit()
    a += 1
N,X = map(int,input().split())
l = list(map(int,input().split()))
p = 0
count = 0

for i in range(N):
    p += l[i]
    count += 1
    if p > X:
        break
print(count)
N, X = list(map(int,input().split()))
L = list(map(int,input().split()))
L.append(0)
Ls = sorted(L)
sum = 0
count = 0
for i in range(N):
  if sum <= X:
    sum += L[i]
    count += 1
print(count)
def main():
    n, x = [int(z) for z in input().split()]
    l = [int(z) for z in input().split()]
    tam = len(l)
    d = 0
    for i in range(tam):
        d += l[i]
        if d > x:
            print(i + 1)
            break
main()
n,x=map(int,input().split())

l=[int(x) for x in input().split()]
d=0
cnt=1
for i in l:
    d+=i
    cnt+=1
    if d >x:
        print(cnt-1)
        break
    elif d==x:
        print(cnt)
        break
def cumsum(xs):
    result = [0,xs[0]]
    for x in xs[1:]:
        result.append(result[-1] + x)
    return result
a,b=map(int,input().split())
c=list(map(int,input().split()))
n=cumsum(c)
for i in range(len(n)):
    if n[i]>b:
        print(i)
        break
N, X = map(int, input().split())
L = [int(x) for x in input().split()]

D = [0] * (N+2)
for i in range(2, N+2):
    D[i] = D[i-1] + L[i-2]
    if D[i] > X:
        print(i-1)
        break
INT = lambda: int(input())
INTM = lambda: map(int,input().split())
STRM = lambda: map(str,input().split())
STR = lambda: str(input())
LIST = lambda: list(map(int,input().split()))
LISTS = lambda: list(map(str,input().split()))
def do():
    n,x=INTM()
    l=LIST()
    ct=0
    temp=0
    for i in range(n):
        temp+=l[i]
        if temp<=x:
            ct+=1
        else:
            break
    print(ct)
if __name__ == '__main__':
    do()
n,x=map(int,input().split())
l=list(map(int,input().split()))
i=z=0
while z<=x and i<n:
    z+=l[i]
    i+=1
    if i==n:
        i+=1
print(i)
inputted = list(map(int, input().split()))
N = inputted[0]
X = inputted[1]
L = list(map(int, input().split()))

x = 0
number_of_bounds = 0
for _i, Li in enumerate(L):
    number_of_bounds = _i + 1
    x += Li
    if x > X: break
    
print(number_of_bounds)
#128 b むずい
n,x=map(int,input().split())
l=list(map(int,input().split()))
z=0
ans=0
for i in range(n):
    z+=l[i]
    if z>=x:
        ans=i+2
        break
print(ans)
N, X = map(int, input().split())
L = list(map(int, input().split()))
d = 0

# ans = 1

# for i in range(N):
#     d += L[i]
#     if d <= X:
#         ans += 1

e = 1


for i in L:
    if d + i <= X:
        d += i
        e += 1

# for i in l:
print(e)
n,x= input().split()
b_list= list(map(int, input().split()))
temp = 0
counter = 0
for i in range(int(n)):
    if (temp<=int(x)):
        counter +=1
        temp += b_list[i]
    else:
        break

print(counter)
n, x = list(map(int, input().split()))
l = list(map(int, input().split()))
c = 0
total = 0
for i in l:
  total += i
  if total > x:
    print(c+1)
    break
  c += 1
N,X=map(int,input().split())
L=list(map(int,input().split()))
v=1
w=0
for i in range (N):
  if X>=w+L[i]:
    v+=1
    w+=L[i]
print(v)
N,X = map(int,input().split())
L = list(map(int,input().split()))

curCoord = 0
n = 1

while (curCoord<=X):
    if (n>N):
        break
    else:
        n=n+1
        curCoord = curCoord+L[n-2]
    
print(str(n-1))
n,x = map(int,input().split())
d = list(map(int,input().split()))
bound = 0
count = 0
for i in range(n):
    count += 1
    bound += d[i]
    if bound > x:
        print(count)
        exit()
print(count)
N, X = map(int, input().split())
L = list(map(int, input().split()))
count = 0
p = 0

for i in L:
  if p > X:
    break
  else:
  	count += 1
  	p += i

print(count)
n,x = map(int,input().split())
l = list(map(int,input().split()))
d = 0
cnt = 0
for i in range(n+1):
	if i <n:
		d += l[i]
		cnt += 1
	if x < d:
		print(cnt)
		exit()
print(cnt)
n,x=map(int,input().split())
L=list(map(int,input().split()))

ans=1
d=0
for i in range(n):
  d+=L[i]
  if d<=x:
    ans+=1
  else:
    print(ans);exit()
N,X=map(int,input().split())
length=list(map(int,input().split()))
ans=0
D=0

for i in range(N):
    if D<=X:
        ans+=1
    else:
        break
    D=D+length[i]
print(ans)
n, x = (int(xi) for xi in input().split())
l = [int(xi) for xi in input().split()]

d=0

count = 0
for xi in range(n):
    if d<x:
        count +=1
    d += l[xi]

if d<x:
    count +=1

print(count)
import math
def main():
    t = [int(t)for t in input().split()]
    n,x = t[0],t[1]

    l = [int(t)for t in input().split()]

    i = 0
    s = 0
    while s<=x and i<n:
        s += l[i]
        i+=1

    print(i)

if __name__ == "__main__":
    main()
N,X=map(int,input().split())
L=list(map(int,input().split()))
Y=[0]
D=0
while D<X:
    for i in range(0,N):
        D=D+L[i]
        Y.append(D)
        if D>=X:
            break
if Y[len(Y)-1]==X:
    print(len(Y))
else:
    print(len(Y)-1)
n,x = map(int,input().split(" "))
l = list(map(int,input().split(" ")))
y = 0
for i in l:
    y += i
if y <= x:
    print(n)
else:
    count = 1
    d = 0
    j = 0
    while d < x:
        d += l[j]
        j += 1
        if d <= x:
            count += 1
    print(count)
n,x = map(int,input().split())
l = list(map(int,input().split()))

ans = 0
count = 1
for i in range(n):
  if (ans + l[i]) <= x:
    ans = ans + l[i]
    count += 1
print(count)
n, x = map(int, input().split())
l = list(int(i) for i in input().split())
d = 0
cnt = 0
for i in range(n):
    d += l[i]
    cnt += 1
    if d >= x:
        break
print(cnt)
N,X=map(int,input().split())

arr=list(map(int,input().split()))
a=0
ans=0

for i in range(N):
    if a<=X:
        ans+=1
    else:
        break
    a=a+arr[i]
print(ans)
w, h, x, y = map(int, input().split())

c_x = w / 2
c_y = h / 2

if c_x == x and c_y == y:
    print(w * h / 2, 1)
else:
    print(w * h / 2, 0)
w,h,x,y=map(int,input().split())
b=0
if x==w/2 and y==h/2:
    b=1
s=w*h/2
print(s,b)
W,H,x,y=map(int,input().strip().split())

a=W*H/2
if x==W/2 and y==H/2:
    b=1
else:
    b=0

print(str(a)+" "+str(b))
W, H ,x ,y = map(int,input().split())

S = W * H /2

if x *2 ==W and y*2 == H:
    print(S,1)
else:
    print(S,0)
w,h,x,y = map(int,input().split())
sq = w*(1/2)*h
if x==(w/2) and y==(h/2):
    print(sq,1)
else:
    print(sq,0)
a, b, x, y = map(int, input().split())

ans = 0
if x + x == a and y + y == b:
    ans = 1
else:
    ans = 0
print(a * b / 2, ans)
a,b,c,d = map(int, input().split())
res1 = a*b/2
res2 = 0
if c*2 == a and d*2 == b:
  res2 = 1
print(res1, res2)
# -*- coding: utf-8 -*-

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

def multi(w, h, x, y):
    core = (w/2, h/2)
    if (x == core[0])^(y == core[1]):
        return False
    elif x == core[0]:
        return True
    else:
        return False

print(w*h/2, 1 if multi(w, h, x, y) else 0)
w,h,x,y=map(int,input().split())
if 2*x==w and 2*y==h:
    a=1
else:
    a=0
print(w*h/2,a)
W,H,x,y = map(int,input().split())
print((H*W)/2, int(W/2 == x and H/2 == y))
W,H,x,y=map(int, input().split())
ans1=H*W/2
if W%2==0 and H%2==0 and x==W//2 and y==H//2:
    ans2=1
else:
    ans2=0

print(ans1, ans2)
#!/usr/bin/env python3


def main():
    W, H, x, y = map(int, input().split())
    area = W * H / 2
    multi = int((x == W / 2) and (y == H / 2))

    print(area, multi)


if __name__ == '__main__':
    main()
W,H,x,y = map(int,input().split())

if ((W/2 == x) and (H/2 == y)) or ((W/2 == y) and (H/2 == x)):
    print(W*H/2,end="")
    print(" ",end="")
    print(1)
else:
    print(W*H/2,end="")
    print(" ",end="")
    print(0)
W,H,x,y = map(int,input().split())
if W/2 == x and H/2 == y:
    ans = 1
else:
    ans = 0
print(H*W/2, ans)
w, h, *xy = map(int, input().split())
print(w*h/2, ([w/2, h/2] == xy)+0)
w,h,x,y=map(int, input().split())

if x==w/2 and y==h/2:
    cnt=1
else:
    cnt=0
print(w*h/2, cnt)
W, H, x, y = map(float, input().split())
ans = W * H / 2
count = 0
if W / 2 == x and H / 2 == y:
  count = 1
print(ans, count)
W, H, x, y = map(int, input().split())

if x == W/2 and y == H/2:
    flag = 1
else:
    flag = 0
print(W*H/2, flag)
w, h, x, y = map(int, input().split())
m = 1 if x == w/2 and y == h/2 else 0
print(w*h/2, m)
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)
w, h, x, y = map(int, input().split())
max_area = w*h/2
flag = 0
if x == w/2 and y == h/2:
    flag = 1
print(max_area, flag)
#中心を通る時面積は二等分される
#つまり大きくない方の面積の最大値はw*h/2
#x、yが中心の時面積を2等分する直線は無限に引くことができる
#中心でない時、中心との結ぶ線は1本しか弾けない

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

print(W*H/2,int(x*2==W and y*2 == H))
w, h, x, y = (int(i) for i in input().split())
s = (w * h) / 2
met = 1 if (x == w/2 and y == h/2) else 0
print(s, met)
W,H,x,y = list(map(int, input().split()))

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

area = w * h / 2

if x == w / 2 and y == h / 2:
    print(area, 1)
else:
    print(area, 0)
import sys
from operator import itemgetter

sys.setrecursionlimit(10**9)
input = sys.stdin.readline

def ii(): return int(input())
def mi(): return map(int, input().split())
def lmi(): return list(map(int, input().split()))
def lmif(n): return [list(map(int, input().split())) for _ in range(n)]
def ss(): return input().split()

def main():
    W, H, x, y = mi()

    s = W*H/2
    cut = 1 if W/2 == x/1 and H/2 == y/1 else 0

    print(s, cut)

    return

main()
W, H, x, y = map(int, input().split())
half_area = W * H /2
if x == W/2 and y == H/2:
    print(half_area, 1)
else:
    print(half_area, 0)
w,h,x,y=map(int,input().split())
if w/2==x and h/2==y:
    ans=1
else:
    ans=0
print(w*h/2,ans)
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)
W, H, x, y = map(int, input().split())

S = W * H / 2

print (S, end = ' ')
if W == 2 * x and H == 2 * y:
    print (1)
else:
    print (0)
W,H,x,y=map(int,input().split())

if x*2==W and y*2==H:
    print(H*W/2,end=" ")
    print(1)
else:
    print(H*W/2,end=" ")
    print(0)
# C - Rectangle Cutting
W,H,x,y = map(int,input().split())
S = W*H

# H,W の中心と x,y の距離
distx = abs(W/2 - x)
disty = abs(H/2 - y)

if distx == disty == 0:
    ans = (S/2,1)
else:
    ans = (S/2,0)
print(*ans)
w,h,x,y=map(int,input().split())
a=w/2
b=h/2
s=w*h/2
cnt=0
if x==a and y==b:
    cnt=1
print(s,cnt)
#create date: 2020-06-29 13:35

import sys
stdin = sys.stdin

def ns(): return stdin.readline().rstrip()
def ni(): return int(ns())
def na(): return list(map(int, stdin.readline().split()))

def main():
    w, h, x, y = na()
    print("{:.10f} {}".format(w*h/2, 1 if w/2==x and h/2==y else 0))

if __name__ == "__main__":
    main()
W, H, x, y = map(int, input().split())
menseki = (W*H)/2
if (x == W/2) & (y == H/2):
	print(str(menseki) + " 1")
else:
	print(str(menseki) + " 0")
import sys
W,H,x,y = map(int, input().split())

ans = W * H / 2

if W / 2 == x and H / 2 == y:
  print("{} {}".format(ans, 1))
else:
  print("{} {}".format(ans, 0))
#ABC130 C-Rectangle Cutting 14:59

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

def func(W,H,x,y):
    if x* 2 == W and y*2 == H:
        return W*H/2, 1
    else:
        return W*H/2, 0
print(*func(W,H,x,y))
a,b,c,d=map(int,input().split())
if a/2==c and b/2==d:
  print(a*b/2,1)
else:
  print(a*b/2,0)
W, H, x, y = map(int, input().split())
print(W*H/2, int(x == W/2 and y == H/2))
w, h, x, y = map(int, input().split())
square = (w * h) / 2
flg = 0
if x == w / 2 and y == h / 2:
    flg = 1
print(square, flg)
W,H,x,y=map(int,input().split())
a=W*H/2
print(a,1) if W/2==x and H/2==y else print(a,0)
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)
W,H,x,y=map(int,input().split())
if x==W/2 and y==H/2:
	c=1
else:
	c=0
print(W*H/2,c)
w, h, x, y = map(int, input().split())

judge = (w == 2 * x and h == 2 * y)
s = w * h / 2
print(s, 1 if judge else 0)
w, h, x, y = map(int, input().split())
s = w * h / 2
if x * 2 == w and y * 2 == h:
    print(s, 1)
else:
    print(s, 0)
w,h,x,y=map(int,input().split())
print(w*(h/2),1*(w/2==x and h/2==y))
W, H, x, y = map(int, input().split())
S = W*H/2
if W == 2*x and H == 2*y:
    print(S, 1)
else:
    print(S, 0)
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)
w,h,x,y=map(int,input().split())
ans1=(w*h)/2.0
ans2=0
if (w/2==x)and(h/2==y):
    ans2=1
print('%f %d'%(ans1,ans2))
# Code for C - Rectangle Cutting
# Use input() to fetch data from STDIN
[d, w, x, y] = [int(x) for x in input().split()]

m = d * w / 2

r = 1 if d / 2 == x and w / 2 == y else 0

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