N, X = map(int,input().split())
LL = list(map(int, input().split()))

mj = 0
cnt = 1
for i in range(N):
    mj += LL[i]
    if mj <= X:
        cnt += 1

print(cnt) N, X = map(int,input().split()) N map(int,input().split()) map int input().split() ().split () input split X LL = list(map(int, input().split())) LL list(map(int, input().split())) list map(int, input().split()) map int input().split() ().split () input split mj = 0 mj 0 cnt = 1 cnt 1 for i in range(N):
    mj += LL[i]
    if mj <= X:
        cnt += 1 i range(N) range N mj += LL[i] mj LL[i] LL i if mj <= X:
        cnt += 1 mj <= X mj X cnt += 1 cnt 1 print(cnt) print cnt N, X = map(int,input().split()) map(int,input().split()) N cnt = 1 1 cnt mj += LL[i] LL[i] mj mj = 0 0 mj X = map(int,input().split()) map(int,input().split()) X LL = list(map(int, input().split())) list(map(int, input().split())) LL cnt += 1 1 cnt
N, X = map(int,input().split())
LL = list(map(int, input().split()))

mj = 0
cnt = 1
for i in range(N):
    mj += LL[i]
    if mj <= X:
        cnt += 1

print(cnt)