N,X = (int(x) for x in input().split())
L = [int(x) for x in input().split()]
s = 0
i = 0
while (s <= X):
  if i >= N:
    print(N+1)
    quit()
  else:
    s = s + L[i]
    i = i + 1
print(i) int(x) for x in input().split() for x in input().split() x input().split() ().split () input split for x in input().split() int(x) int x N,X = (int(x) for x in input().split()) N (int(x) for x in input().split()) X int(x) for x in input().split() for x in input().split() x input().split() ().split () input split for x in input().split() int(x) int x L = [int(x) for x in input().split()] L [int(x) for x in input().split()] s = 0 s 0 i = 0 i 0 while (s <= X):
  if i >= N:
    print(N+1)
    quit()
  else:
    s = s + L[i]
    i = i + 1 s <= X s X if i >= N:
    print(N+1)
    quit()
  else:
    s = s + L[i]
    i = i + 1 i >= N i N print(N+1) print N+1 N 1 quit() quit s = s + L[i] s s + L[i] s L[i] L i i = i + 1 i i + 1 i 1 print(i) print i X = (int(x) for x in input().split()) (int(x) for x in input().split()) X s = s + L[i] s + L[i] s s = 0 0 s i = i + 1 i + 1 i i = 0 0 i N,X = (int(x) for x in input().split()) (int(x) for x in input().split()) N L = [int(x) for x in input().split()] [int(x) for x in input().split()] L
N,X = (int(x) for x in input().split())
L = [int(x) for x in input().split()]
s = 0
i = 0
while (s <= X):
  if i >= N:
    print(N+1)
    quit()
  else:
    s = s + L[i]
    i = i + 1
print(i)