Buggy python submission (verdict: Runtime Error):
N, X=map(int, input().split())
L=list(map(int, input().split()))
L=[0]+L
 
l=int(0)
counter=int(0)
while l+L[counter]<=X and counter<N+1:
  l+=L[counter]
  counter+=int(1)
  
print(counter)

Fixed submission:
import numpy as np

temp=list(map(int, input().split()))

N=temp[0]
X=temp[1]

L=list(map(int, input().split()))

ind=1
while np.sum(L[:ind])<=X and ind<=N:
  ind+=1
  
print(ind)

Buggy python submission (verdict: Runtime Error):
N, X=map(int, input().split())
L=list(map(int, input().split()))
 
l=int(0)
counter=int(0)
while l<=X and counter<=N+1:
  l+=L[counter]
  counter+=int(1)
  
print(counter)

Fixed submission:
import numpy as np

temp=list(map(int, input().split()))

N=temp[0]
X=temp[1]

L=list(map(int, input().split()))

ind=1
while np.sum(L[:ind])<=X and ind<=N:
  ind+=1
  
print(ind)

Buggy python submission (verdict: Runtime Error):
N, X=map(int, input().split())
L=list(map(int, input().split()))
 
l=int(0)
counter=int(0)
while l<=X:
  l+=L[counter]
  counter+=int(1)
  
print(counter)

Fixed submission:
import numpy as np

temp=list(map(int, input().split()))

N=temp[0]
X=temp[1]

L=list(map(int, input().split()))

ind=1
while np.sum(L[:ind])<=X and ind<=N:
  ind+=1
  
print(ind)

Buggy python submission (verdict: Runtime Error):
N, X=map(int, input().split())
L=list(map(int, input().split()))

l=0
counter=0
while l<=X:
  l+=L[counter]
  counter+=1
  
print(counter)

Fixed submission:
import numpy as np

temp=list(map(int, input().split()))

N=temp[0]
X=temp[1]

L=list(map(int, input().split()))

ind=1
while np.sum(L[:ind])<=X and ind<=N:
  ind+=1
  
print(ind)

Buggy python submission (verdict: Runtime Error):
N, X=map(int, input().split())
L=list(map(int, input().split()))

length=0
counter=0
while l<=X:
  length+=L[counter]
  counter+=1
  
print(counter)

Fixed submission:
import numpy as np

temp=list(map(int, input().split()))

N=temp[0]
X=temp[1]

L=list(map(int, input().split()))

ind=1
while np.sum(L[:ind])<=X and ind<=N:
  ind+=1
  
print(ind)

Buggy python submission (verdict: Runtime Error):
N, X=map(int, input().split())
L=list(map(int, input().split()))

length=0
counter=0
while l<=X:
  length+=L[counter]
  counter+=1

Fixed submission:
import numpy as np

temp=list(map(int, input().split()))

N=temp[0]
X=temp[1]

L=list(map(int, input().split()))

ind=1
while np.sum(L[:ind])<=X and ind<=N:
  ind+=1
  
print(ind)

Buggy python submission (verdict: Runtime Error):
N, X=map(int, input().split())
L=list(map(int, input().split()))

l=0
counter=0
while l<=X:
  l+=L[counter]
  counter+=1

Fixed submission:
import numpy as np

temp=list(map(int, input().split()))

N=temp[0]
X=temp[1]

L=list(map(int, input().split()))

ind=1
while np.sum(L[:ind])<=X and ind<=N:
  ind+=1
  
print(ind)

Buggy python submission (verdict: Runtime Error):
N, X=map(int, input().split())
L=list(map(int, input().split()))

l=0
counter=0
while l<=X:
  l+=L[counter-1]
  counter+=1

Fixed submission:
import numpy as np

temp=list(map(int, input().split()))

N=temp[0]
X=temp[1]

L=list(map(int, input().split()))

ind=1
while np.sum(L[:ind])<=X and ind<=N:
  ind+=1
  
print(ind)

Buggy python submission (verdict: Runtime Error):
temp=list(map(int, input().split()))

N=temp[0]
X=temp[1]

L=list(map(int, input().split()))

ind=1
while np.sum(L[:ind])<=X and ind<N:
  ind+=1
  
print(ind)

Fixed submission:
import numpy as np

temp=list(map(int, input().split()))

N=temp[0]
X=temp[1]

L=list(map(int, input().split()))

ind=1
while np.sum(L[:ind])<=X and ind<=N:
  ind+=1
  
print(ind)