N,X = map(int,input().split())
L = list(map(int,input().split()))
count = 1
posi = 0
for i in L:
    posi +=i
    if(posi<=X):
        count+=1
    else:
        break
print(count) N,X = map(int,input().split()) N map(int,input().split()) map int input().split() ().split () input split X L = list(map(int,input().split())) L list(map(int,input().split())) list map(int,input().split()) map int input().split() ().split () input split count = 1 count 1 posi = 0 posi 0 for i in L:
    posi +=i
    if(posi<=X):
        count+=1
    else:
        break i L posi +=i posi i if(posi<=X):
        count+=1
    else:
        break posi<=X posi X count+=1 count 1 break print(count) print count posi +=i i posi count+=1 1 count X = map(int,input().split()) map(int,input().split()) X L = list(map(int,input().split())) list(map(int,input().split())) L count = 1 1 count posi = 0 0 posi N,X = map(int,input().split()) map(int,input().split()) N
N,X = map(int,input().split())
L = list(map(int,input().split()))
count = 1
posi = 0
for i in L:
    posi +=i
    if(posi<=X):
        count+=1
    else:
        break
print(count)