a = input()
b = a.split(" ")
b = b[1:]
for i in b:
    b[b.index(i)] = int(i)
t = 0
d = 0
counter = 0
a = 0
for i in b:
    counter = counter +1
    if counter%2!=0:
        t = t+i
    else:
        d = d+i
        if t>d or t==d:
            t = 0
            a = a+1
        else:
            d = 0
print(a)
            
    
