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) import sys sys N, X = map(int, sys.stdin.readline().split()) N map(int, sys.stdin.readline().split()) map int sys.stdin.readline().split() sys.stdin.readline().split sys.stdin.readline() sys.stdin.readline sys.stdin sys stdin readline split X L = list(map(int, sys.stdin.readline().split())) L list(map(int, sys.stdin.readline().split())) list map(int, sys.stdin.readline().split()) map int sys.stdin.readline().split() sys.stdin.readline().split sys.stdin.readline() sys.stdin.readline sys.stdin sys stdin readline split ans = 0 ans 0 for i, l in enumerate(L):
    ans += l
    if ans > X:
        print(i+1)
        break
else:
    print(N+1) i l enumerate(L) enumerate L ans += l ans l if ans > X:
        print(i+1)
        break ans > X ans X print(i+1) print i+1 i 1 break print(N+1) print N+1 N 1 ans += l l ans ans = 0 0 ans N, X = map(int, sys.stdin.readline().split()) map(int, sys.stdin.readline().split()) N L = list(map(int, sys.stdin.readline().split())) list(map(int, sys.stdin.readline().split())) L X = map(int, sys.stdin.readline().split()) map(int, sys.stdin.readline().split()) X
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)