Buggy python submission (verdict: Runtime Error):
import numpy as np
N=int(input())
P=np.array(list(map(int, input().split())))



mini=1
count=1
index_min=P.argmin()
while P[0]>mini:
  if P==np.sort(a)[::-1]:
    count+=P.shape[0]
    break
  P=P[:index_min]
  mini=min(P)
  index_min=P.argmin()
  count+=1
"""
count=1
for i in range(1,N):
  if min(P[:i+1])==P[i]:
    count+=1
"""
print(count)



Fixed submission:
n=int(input())
p=list(map(int, input().split()))
ans=1
l=[p[0]]
buf=p[0]
for i in range(1,n):
    l.append(p[i])
    if p[i]<=buf:
        ans+=1
        buf=p[i]
print(ans)

Buggy python submission (verdict: Runtime Error):
import numpy as np
N=int(input())
P=np.array(list(map(int, input().split())))



mini=1
count=1
index_min=P.argmin()
while P[0]>mini:
  if P==P.sort()[::-1]:
    count+=P.shape[0]
    break
  P=P[:index_min]
  mini=min(P)
  index_min=P.argmin()
  count+=1
"""
count=1
for i in range(1,N):
  if min(P[:i+1])==P[i]:
    count+=1
"""
print(count)



Fixed submission:
n=int(input())
p=list(map(int, input().split()))
ans=1
l=[p[0]]
buf=p[0]
for i in range(1,n):
    l.append(p[i])
    if p[i]<=buf:
        ans+=1
        buf=p[i]
print(ans)

Buggy python submission (verdict: Time Limit Exceeded):
import numpy as np
N=int(input())
P=np.array(list(map(int, input().split())))



mini=1
count=1
index_min=P.argmin()
while P[0]>mini:
  P=P[:index_min]
  mini=min(P)
  index_min=P.argmin()
  count+=1
"""
count=1
for i in range(1,N):
  if min(P[:i+1])==P[i]:
    count+=1
"""
print(count)



Fixed submission:
n=int(input())
p=list(map(int, input().split()))
ans=1
l=[p[0]]
buf=p[0]
for i in range(1,n):
    l.append(p[i])
    if p[i]<=buf:
        ans+=1
        buf=p[i]
print(ans)

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



mini=1
count=1
index_min=P.index(mini)
for i in range(N):
  P=P[:index_min]
  mini=min(P)
  index_min=P.index(mini)
  count+=1
  if mini==P[0]:
    break
  
"""
count=1
for i in range(1,N):
  if min(P[:i+1])==P[i]:
    count+=1
"""
print(count)



Fixed submission:
n=int(input())
p=list(map(int, input().split()))
ans=1
l=[p[0]]
buf=p[0]
for i in range(1,n):
    l.append(p[i])
    if p[i]<=buf:
        ans+=1
        buf=p[i]
print(ans)

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



mini=1
count=1
index_min=P.index(mini)
for i in range(N):
  P=P[:index_min]
  mini=min(P)
  index_min=P.index(mini)
  count+=1
  if mini==P[0]:
    break
  
"""
count=1
for i in range(1,N):
  if min(P[:i+1])==P[i]:
    count+=1
"""
print(count)



Fixed submission:
n=int(input())
p=list(map(int, input().split()))
ans=1
l=[p[0]]
buf=p[0]
for i in range(1,n):
    l.append(p[i])
    if p[i]<=buf:
        ans+=1
        buf=p[i]
print(ans)

Buggy python submission (verdict: Time Limit Exceeded):
N=int(input())
P=list(map(int, input().split()))



mini=1
count=1
index_min=P.index(mini)
while P[0]>mini:
  P=P[:index_min]
  mini=min(P)
  index_min=P.index(mini)
  count+=1
"""
count=1
for i in range(1,N):
  if min(P[:i+1])==P[i]:
    count+=1
"""
print(count)



Fixed submission:
n=int(input())
p=list(map(int, input().split()))
ans=1
l=[p[0]]
buf=p[0]
for i in range(1,n):
    l.append(p[i])
    if p[i]<=buf:
        ans+=1
        buf=p[i]
print(ans)

Buggy python submission (verdict: Time Limit Exceeded):
N=int(input())
P=list(map(int, input().split()))
count=1
for i in range(1,N):
  if min(P[:i+1])==P[i]:
    count+=1
print(count)

Fixed submission:
n=int(input())
p=list(map(int, input().split()))
ans=1
l=[p[0]]
buf=p[0]
for i in range(1,n):
    l.append(p[i])
    if p[i]<=buf:
        ans+=1
        buf=p[i]
print(ans)

Buggy python submission (verdict: Time Limit Exceeded):
N=int(input())
P=list(map(int, input().split()))
count=1
for i in range(1,N):
  if min(P[:i+1])>=P[i]:
    count+=1
print(count)

Fixed submission:
n=int(input())
p=list(map(int, input().split()))
ans=1
l=[p[0]]
buf=p[0]
for i in range(1,n):
    l.append(p[i])
    if p[i]<=buf:
        ans+=1
        buf=p[i]
print(ans)