Harryxun/testdata huggingface dataset:
Buggy python submission (verdict: Time Limit Exceeded):
n=int(input())
ai = list(map(int,input().split()))
kei = 0
last = 0
S = []
for i in range(0,n-1):
    for k in range(1,n-i):
      kei = ai[i]*ai[i+k]
      S.append(kei)
last = sum(S) % (10**9 + 7)      
print(last)

Fixed submission:
N=int(input())
A=list(map(int,input().split()))
ans = 0
last = 0

for i in range(N):
    ans += A[i]*A[i]
last += sum(A)*sum(A)
last -= ans
last //= 2
print(last % 1000000007)

Buggy python submission (verdict: Time Limit Exceeded):
n=int(input())
ai = list(map(int,input().split()))
sum = 0
for i in range(0,n-1):
    for k in range(1,n-i):
      sum += ai[i]*ai[i+k]
sum %= 1000000007
print(sum)

Fixed submission:
N=int(input())
A=list(map(int,input().split()))
ans = 0
last = 0

for i in range(N):
    ans += A[i]*A[i]
last += sum(A)*sum(A)
last -= ans
last //= 2
print(last % 1000000007)

Buggy python submission (verdict: Runtime Error):
n=int(input())
ai = list(map(int,input().split()))
sum = 0
i=0
k=1
while i<n-1:
    while k<n-i:
    sum += ai[i]*ai[i+k]
    k++
  i++
sum %= 1000000007
print(sum)

Fixed submission:
N=int(input())
A=list(map(int,input().split()))
ans = 0
last = 0

for i in range(N):
    ans += A[i]*A[i]
last += sum(A)*sum(A)
last -= ans
last //= 2
print(last % 1000000007)
Buggy python submission (verdict: Runtime Error):
n=input()
l=list(map(int,input().split()))
count=0
for i in range(n):
    if i%2==1 and l[i]%2==1:
        count += 1
print(count)

Fixed submission:
n=int(input())
l=list(map(int,input().split()))
count=0
for i in range(n):
    if i%2==0 and l[i]%2==1:
        count += 1
print(count)

Buggy python submission (verdict: Runtime Error):
n=input()
l=list(map(int,input().split))
count=0
for i in range(n):
    if i%2==1 and l%2==1:
        count += 1
print(count)

Fixed submission:
n=int(input())
l=list(map(int,input().split()))
count=0
for i in range(n):
    if i%2==0 and l[i]%2==1:
        count += 1
print(count)

Buggy python submission (verdict: Runtime Error):
n=input()
l=list(map(int,input().split))
l.sort()
count=0
for i in range(n):
    if i%2==1 and l[i]%2==1:
        count += 1
print(count)

Fixed submission:
n=int(input())
l=list(map(int,input().split()))
count=0
for i in range(n):
    if i%2==0 and l[i]%2==1:
        count += 1
print(count)
Buggy python submission (verdict: Runtime Error):
N=int(input())
s=[]
for i in range(N):
    s.append(input())
print("AC x ",s.count("AC"))
print("WA x ",s.count("WA"))
print("TLE x ",s.count("TLE"))
print("RE x ",s.count("RE"))

Fixed submission:

n=int(input())
if n%1000==0:
    print('0')
else:
    k = n
    k += 1000
    k //= 1000
    cha = k*1000-n
    print(cha)
Buggy python submission (verdict: Runtime Error):
N=int(input())
s=""
for i in range(N):
    s.append(input())
print("AC x ".join(s.count("AC")))
print("WA x ".join(s.count("WA")))
print("TLE x ".join(s.count("TLE")))
print("RE x ".join(s.count("RE")))

Fixed submission:
N=int(input())
s=[]
for i in range(N):
    s.append(input())
print("AC x ",s.count("AC"))
print("WA x ",s.count("WA"))
print("TLE x ",s.count("TLE"))
print("RE x ",s.count("RE"))

Buggy python submission (verdict: Runtime Error):
N=int(input())
s=[]
for i in range(N):
    s.append(input())
print("AC x "+s.count("AC"))
print("WA x "+s.count("WA"))
print("TLE x "+s.count("TLE"))
print("RE x "+s.count("RE"))

Fixed submission:
N=int(input())
s=[]
for i in range(N):
    s.append(input())
print("AC x ",s.count("AC"))
print("WA x ",s.count("WA"))
print("TLE x ",s.count("TLE"))
print("RE x ",s.count("RE"))

Buggy python submission (verdict: Runtime Error):
N=int(input())
s=" "
for i in range(N):
    s.append(input())
print("AC x "+s.count("AC"))
print("WA x "+s.count("WA"))
print("TLE x "+s.count("TLE"))
print("RE x "+s.count("RE"))

Fixed submission:
N=int(input())
s=[]
for i in range(N):
    s.append(input())
print("AC x ",s.count("AC"))
print("WA x ",s.count("WA"))
print("TLE x ",s.count("TLE"))
print("RE x ",s.count("RE"))

Buggy python submission (verdict: Runtime Error):

N=int(input())
s=""
for i in range(N):
    s.append(input())
print('AC x '+s.count('AC'))
print('WA x '+s.count('WA'))
print('TLE x '+s.count('TLE'))
print('RE x '+s.count('RE'))

Fixed submission:
N=int(input())
s=[]
for i in range(N):
    s.append(input())
print("AC x ",s.count("AC"))
print("WA x ",s.count("WA"))
print("TLE x ",s.count("TLE"))
print("RE x ",s.count("RE"))
Buggy python submission (verdict: Runtime Error):
k = int,input()
l = input()
if(len(l)<k):
    print(l)
else:
    print(l)
    print("...")

Fixed submission:

k=int(input())
s=input()
l=len(s)
if l<=k:
    print(s)
else:
    print(s[:k]+"...")
Buggy python submission (verdict: Runtime Error):
n = map(int,input.split())
if '7' in n:
    print('Yes')
else:
    print('No')

Fixed submission:
n = input()
if '7' in n:print('Yes')
else:print('No')

Buggy python submission (verdict: Runtime Error):
n = map(int,input.split())
if 7 in n:print('Yes')
else:print('No')

Fixed submission:
n = input()
if '7' in n:print('Yes')
else:print('No')
Buggy python submission (verdict: Runtime Error):
s=list(map(str,input().split()))
if s[2]==s[3] and s[4]==s[5]:
    print('Yes')
else:
    print('No')

Fixed submission:
s=list(input())
if s[2]==s[3] and s[4]==s[5]:
    print('Yes')
else:
    print('No')
Buggy python submission (verdict: Runtime Error):
n=input()
k=n%500
n -= k*500
n //= 5
print(k*1000+n*5)

Fixed submission:
n=int(input())
k=n//500
n -= k*500
n //= 5
print(k*1000+n*5)
Buggy python submission (verdict: Runtime Error):
n,k=map(int,input().split())
count=0
while int(m)!=0:
    int(m)= n/k
    n=int(m)
    count += 1
print(count)

Fixed submission:
n,k=map(int,input().split())
count=0
while n !=0:
    n //= k
    count += 1
print(count)

Buggy python submission (verdict: Runtime Error):
n,k=map(int,input().split())
count=0
while m!=0:
    int(m) = n/k
    n=m
    count += 1
print(count)

Fixed submission:
n,k=map(int,input().split())
count=0
while n !=0:
    n //= k
    count += 1
print(count)

Buggy python submission (verdict: Time Limit Exceeded):
n,r = map(int,input().split())
i = 0
while n > 0:
    n / r
    i += 1
print(i)

Fixed submission:
n,k=map(int,input().split())
count=0
while n !=0:
    n //= k
    count += 1
print(count)
Buggy python submission (verdict: Runtime Error):
f,s=map(int,input.split())
if f==s:
    print('Yes')
else :
    print('No')


Fixed submission:
N,M = (int(i) for i in input().split())
if N==M: 
    print('Yes')
else:
    print('No')

Buggy python submission (verdict: Runtime Error):
f,s=map(int,input.split())
if f==s:
    print('Yes')
elif :
    print('No')


Fixed submission:
N,M = (int(i) for i in input().split())
if N==M: 
    print('Yes')
else:
    print('No')
Buggy python submission (verdict: Runtime Error):
n=int(input())
for i in range(9):
    for j in range(9):
        k = (i+1)*(j+1)
        if n%k==0:
            print('Yes')
        else:
            print('No')

Fixed submission:

a,b=map(int,input().split())
if a<10 and b<10:
    print(a*b)
else:
    print('-1')
Buggy python submission (verdict: Runtime Error):
n=int(input())
for i in range(9):
    for j in range(9):
        k = i*j
        if n%k==0:
            print('Yes')
            exit()
        else:
            continue
print('No')

Fixed submission:
n=int(input())
for i in range(9):
    for j in range(9):
        k = (i+1)*(j+1)
        if n==k:
            print('Yes')
            exit()
        else:
            continue
print('No')

Buggy python submission (verdict: Runtime Error):

n=int(input())
for i in range(9):
    for j in range(9):
        if n%(i*j)==0:
            print('Yes')
        else:
            print('No')

Fixed submission:
n=int(input())
for i in range(9):
    for j in range(9):
        k = (i+1)*(j+1)
        if n==k:
            print('Yes')
            exit()
        else:
            continue
print('No')
Buggy python submission (verdict: Runtime Error):
n=int(input())
d=list(map(int,input().split()))
s=0
for i in range(n):
    for j in range[i+1:]:
        s += d[i]*d[j]
print(s)

Fixed submission:

n=int(input())
d=list(map(int,input().split()))
s=0
for i in range(n):
    for j in range(i+1,n):
        s += d[i]*d[j]
print(s)

Buggy python submission (verdict: Runtime Error):
n=int(input())
d=list(map(int,input().split()))
s=0
for i in range(n):
    for j in range(i+1:):
        s += i*j
print(s)

Fixed submission:

n=int(input())
d=list(map(int,input().split()))
s=0
for i in range(n):
    for j in range(i+1,n):
        s += d[i]*d[j]
print(s)
Buggy python submission (verdict: Runtime Error):
n=int(input())
if len(n)==1:
    print(n)
elif len(n)==2:
    print(9)
elif len(n)==3:
    print(n-90)
elif len(n)==4:
    print('909')
elif len(n)==5:
    print(n-9090)
else:
    print('90909')

Fixed submission:
n=input()
if len(n)==1:
    print(n)
elif len(n)==2:
    print('9')
elif len(n)==3:
    print(int(n)-90)
elif len(n)==4:
    print('909')
elif len(n)==5:
    print(int(n)-9090)
else:
    print('90909')
Buggy python submission (verdict: Runtime Error):

n=int(input())
p=list(map(int,input().split()))
new_p=p.sort()
cnt=0

for i in range(n):
    if p[i] != new_p[i]:
        cnt += 1
        
if cnt > 2:
    print('NO')
else:
    print('YES')

Fixed submission:
n=int(input())
p=list(map(int,input().split()))
new_p=sorted(p)
cnt=0

for i in range(n):
    if p[i] != new_p[i]:
        cnt += 1
        
if cnt > 2:
    print('NO')
else:
    print('YES')

Buggy python submission (verdict: Runtime Error):
n=int(input())
p=list(map(int,input().split()))
new_p=p.reverse()
cnt=0

for i in range(n-1):
    if p[i] != new_p[i]:
        cnt += 1
        
if cnt > 2:
    print('NO')
else:
    print('YES')

Fixed submission:
n=int(input())
p=list(map(int,input().split()))
new_p=sorted(p)
cnt=0

for i in range(n):
    if p[i] != new_p[i]:
        cnt += 1
        
if cnt > 2:
    print('NO')
else:
    print('YES')

Buggy python submission (verdict: Runtime Error):
n=int(input())
p=list(map(int,input().split()))
new_p=p.reverse()

for i in range(n):
    if p[i]<p[i+1]:
        tmp=p[i]
        p[i]=p[i+1]
        p[i+1]=tmp
        break
if new_p==p:
    print('YES')
else:
    print('NO')

Fixed submission:
n=int(input())
p=list(map(int,input().split()))
new_p=sorted(p)
cnt=0

for i in range(n):
    if p[i] != new_p[i]:
        cnt += 1
        
if cnt > 2:
    print('NO')
else:
    print('YES')

Buggy python submission (verdict: Runtime Error):
n=int(input())
p=list(map(int,input().split()))
new_p=p.reversesort()

for i in range(n-1):
    if p[i]<=p[i+1]:
        tmp=p[i]
        p[i]=p[i+1]
        p[i+1]=tmp
        break
if new_p==p:
    print('YES')
else:
    print('NO')

Fixed submission:
n=int(input())
p=list(map(int,input().split()))
new_p=sorted(p)
cnt=0

for i in range(n):
    if p[i] != new_p[i]:
        cnt += 1
        
if cnt > 2:
    print('NO')
else:
    print('YES')
Buggy python submission (verdict: Runtime Error):
n=int(input())
p=map(int,input().split())
count=0
for i in range(0,n-2):
    if (p[i]<p[i+1] and p[i+1]<p[i+2]) or (p[i]>p[i+1] and p[i+1]>p[i+2]):
        count += 1
print(count)


Fixed submission:
n=int(input())
p=list(map(int,input().split()))
count=0
for i in range(0,n-2):
    if (p[i]<p[i+1] and p[i+1]<p[i+2]) or (p[i]>p[i+1] and p[i+1]>p[i+2]):
        count += 1
print(count)

Buggy python submission (verdict: Runtime Error):
n=int(input())
p=map(int,input().split())
count=0
for i in range(0,n-3):
    if (p[i]<p[i+1] and p[i+1]<p[i+2]) or (p[i]>p[i+1] and p[i+1]>p[i+2]):
        count += 1
print(count)

Fixed submission:
n=int(input())
p=list(map(int,input().split()))
count=0
for i in range(0,n-2):
    if (p[i]<p[i+1] and p[i+1]<p[i+2]) or (p[i]>p[i+1] and p[i+1]>p[i+2]):
        count += 1
print(count)
Buggy python submission (verdict: Runtime Error):
N,L=map(int,input().split())
s = N*L+sum(1,N+1)-N
K=[]
for i in range(1,N+1):  
    K.append(L+i-1)
if 0 <= K[0]:
    s -= K[0]
elif K[0]<0 and K[N-1]>0:
    s = s
else:
    s -= K[N-1]
print(s)

Fixed submission:
N,L=map(int,input().split())
s = N*L
for i in range (N+1):
    s += i
s -= N
K=[]
for i in range(1,N+1):  
    K.append(L+i-1)
if 0 <= K[0]:
    s -= K[0]
elif K[0]<0 and K[N-1]>0:
    s = s
else:
    s -= K[N-1]
print(s)

Buggy python submission (verdict: Runtime Error):
N,L=map(int,input().split())
s = N*L+sum(1,N+1)-N
K=''
for i in range(1,N+1):  
    K.append(L+i-1)
if 0 <= K[0]:
    s -= K[0]
elif K[0]<0 and K[N-1]>0:
    s = s
else:
    s -= K[N-1]
print(s)

Fixed submission:
N,L=map(int,input().split())
s = N*L
for i in range (N+1):
    s += i
s -= N
K=[]
for i in range(1,N+1):  
    K.append(L+i-1)
if 0 <= K[0]:
    s -= K[0]
elif K[0]<0 and K[N-1]>0:
    s = s
else:
    s -= K[N-1]
print(s)
Buggy python submission (verdict: Runtime Error):
n=int(input())
k=0
v=[map(int,input().split())]
c=[map(int,input().split())]
for i in range(n):
    if (v[i]-c[i])>0:
        k += (v[i]-c[i])
print(k)

Fixed submission:
n=int(input())
k=0
v=list(map(int,input().split()))
c=list(map(int,input().split()))
for i in range(n):
    if (v[i]-c[i])>0:
        k += (v[i]-c[i])
print(k)

Buggy python submission (verdict: Runtime Error):
n=int(input())
k=0
for i in range(n):
    v=map(int,input().split())
    c=map(int,input().split())
    if v>c:
        k += (v-c)
print(k)


Fixed submission:
n=int(input())
k=0
v=list(map(int,input().split()))
c=list(map(int,input().split()))
for i in range(n):
    if (v[i]-c[i])>0:
        k += (v[i]-c[i])
print(k)

Buggy python submission (verdict: Runtime Error):
n=int(input())
k=0
for i in range(n):
    v=map(int,input().split())
    c=map(int,input().split())
    if v>c:
        k += (v-c)
print(k)


Fixed submission:
n=int(input())
k=0
v=list(map(int,input().split()))
c=list(map(int,input().split()))
for i in range(n):
    if (v[i]-c[i])>0:
        k += (v[i]-c[i])
print(k)
Buggy python submission (verdict: Runtime Error):
a,b,k=map(int,input().split())
N=""
for i in range(1,min(a,b)):
    if a%i==0 and b%i==0:
            N.append(i)
N.reverse()
print(N[k-1])

Fixed submission:
a,b,k=map(int,input().split())
N=[]
for i in range(1,min(a,b)+1):
    if (a%i==0 and b%i==0):
            N.append(i)
N.reverse()
print(N[k-1])

Buggy python submission (verdict: Runtime Error):
a,b,k=map(int,input().split())
l,s=0
N=""
while s < k:
    l += 1
    if a%(l+1)==0 and b%(l+1)==0:
            s += 1
            N.append(l)
N.reverse()
print(N[k-1])

Fixed submission:
a,b,k=map(int,input().split())
N=[]
for i in range(1,min(a,b)+1):
    if (a%i==0 and b%i==0):
            N.append(i)
N.reverse()
print(N[k-1])

Buggy python submission (verdict: Runtime Error):
a,b,k=map(int,input().split())
l,s=0
while s < k:
    l += 1
    if a%(l+1)==0 and b%(l+1)==0:
            s += 1
print(l)

Fixed submission:
a,b,k=map(int,input().split())
N=[]
for i in range(1,min(a,b)+1):
    if (a%i==0 and b%i==0):
            N.append(i)
N.reverse()
print(N[k-1])
Buggy python submission (verdict: Runtime Error):
y,m,d=map(int,input().split('/'))
if y < 2020 and m < 05:
    print('Heisei')
else:
    print('TBD')

Fixed submission:

y,m,d=map(int,input().split('/'))
if y < 2020 and m < 5:
    print('Heisei')
else:
    print('TBD')
Buggy python submission (verdict: Runtime Error):
n=int(input())
kei = 0.0
for i in range(n):
    x,u=map(str,input().split())
    if u=="JPY":
        kei += float(x[i])
    else:
        kei += float(x[i])*380000.0
print(kei)

Fixed submission:
n=int(input())
kei = 0.0
for i in range(n):
    x,u=map(str,input().split())
    if u=="JPY":
        kei += float(x)
    else:
        kei += float(x)*380000.0
print(kei)

Buggy python submission (verdict: Runtime Error):
n=int(input())
kei = 0.0
for i in range(n):
    x=list(input().split())
    u=list(map(str,input().split()))
    if u[i]=="JPY":
        kei += float(x[i])
    else:
        kei += float(x[i])*380000.0
print(kei)

Fixed submission:
n=int(input())
kei = 0.0
for i in range(n):
    x,u=map(str,input().split())
    if u=="JPY":
        kei += float(x)
    else:
        kei += float(x)*380000.0
print(kei)

Buggy python submission (verdict: Runtime Error):
n=int(input())
kei = 0.0
for i in range(n):
    x,u=list(map(input().split()))
    if u[i]=="JPY":
        kei += float(int(x[i]))
    else:
        kei += float(x[i])*380000.0
print(kei)

Fixed submission:
n=int(input())
kei = 0.0
for i in range(n):
    x,u=map(str,input().split())
    if u=="JPY":
        kei += float(x)
    else:
        kei += float(x)*380000.0
print(kei)

Buggy python submission (verdict: Runtime Error):
n=int(input())
kei = 0.0
for i in range (n):
    x,u=list(map(input().split()))
    if u[i]=="JPY":
        kei += float(int(x[i]))
    else:
        kei += float(x[i])*380000.0
print(kei)


Fixed submission:
n=int(input())
kei = 0.0
for i in range(n):
    x,u=map(str,input().split())
    if u=="JPY":
        kei += float(x)
    else:
        kei += float(x)*380000.0
print(kei)

Buggy python submission (verdict: Runtime Error):
n=int(input())
kei = 0.0
for i in range (n):
    x,u=list(map(input().split()))
    if u[i]=='JPY':
        kei += float(int(x[i]))
    else:
        kei += float(x[i])*380000
print(kei)


Fixed submission:
n=int(input())
kei = 0.0
for i in range(n):
    x,u=map(str,input().split())
    if u=="JPY":
        kei += float(x)
    else:
        kei += float(x)*380000.0
print(kei)

Buggy python submission (verdict: Runtime Error):
n=int(input())
kei = 0
for i in range (n):
    x,u=list(map(input().split()))
    if u[i]=='JPY':
        kei += int(x[i])
    else:
        kei += int(x[i])*380000
print(kei)


Fixed submission:
n=int(input())
kei = 0.0
for i in range(n):
    x,u=map(str,input().split())
    if u=="JPY":
        kei += float(x)
    else:
        kei += float(x)*380000.0
print(kei)
Buggy python submission (verdict: Runtime Error):
n=int(input())
L=list(map(int,input().split()))
L.sort()
ans=sum(L)-L[n-1]
if ans>L[n-1]:
    print('Yes')
else:
    print('No')

Fixed submission:
a,b=map(int,input().split())
print(a/b)
Buggy python submission (verdict: Runtime Error):

n=int(input())
L=list(map(int,input().split()))
L.sort()
ans=sum(L[:n-1])
if ans>L[n-1:n]:
    print('Yes')
else:
    print('No')

Fixed submission:
n=int(input())
L=list(map(int,input().split()))
L.sort()
ans=sum(L)-L[n-1]
if ans>L[n-1]:
    print('Yes')
else:
    print('No')
Buggy python submission (verdict: Runtime Error):

N=int(input())
cnt=N.count('2')
print(cnt)

Fixed submission:

N=input()
cnt=N.count('2')
print(cnt)

Buggy python submission (verdict: Runtime Error):

N=list(int(input()))
cnt=N.count('2')
print(cnt)

Fixed submission:

N=input()
cnt=N.count('2')
print(cnt)
Buggy python submission (verdict: Runtime Error):
S=str(input())
if len(S)==2:
    print(S)
else:
    print(S.reverse())

Fixed submission:

S=str(input())
if len(S)==2:
    print(S)
else:
    print(S[::-1])
Buggy python submission (verdict: Runtime Error):
N,T=map(int,input().split())
k=1000
l=1
for i in range(N):
    c,t = int(input())
    if t[i] <= T:
        l=0
        if c[i] < k:
            k = c[i]
if l==1:
    print('TLE')
else:
    print(k)

Fixed submission:
N,T=map(int,input().split())
k=1000
l=1
for i in range(N):
    c,t=map(int,input().split())
    if t <= T:
        l=0
        if c < k:
            k = c
if l==1:
    print('TLE')
else:
    print(k)

Buggy python submission (verdict: Runtime Error):
n,T=map(int,input().split())
c=list(map(int,input().split('\n')))
k=1000
l=1
for i in range(n):
    if c[i][1] <= T:
        l=0
        if c[i][0] < k:
            k = c[i][0]
if l==1:
    print('TLE')
else:
    print(k)

Fixed submission:
N,T=map(int,input().split())
k=1000
l=1
for i in range(N):
    c,t=map(int,input().split())
    if t <= T:
        l=0
        if c < k:
            k = c
if l==1:
    print('TLE')
else:
    print(k)
Buggy python submission (verdict: Runtime Error):
n=input()
l=len(n)
k=0
for i in range(l):
    for j in range(i,l):
        if n[i]!=n[j]:
            k=1
            
if k==1:
    if n[0]>n[1]:
        print(n[0]*l)
    else:
        print((n[0]+1)*l)
        
else:
    print(n)

Fixed submission:
n=input()
k = int(n) % 111
if k==0:
    print(n)
else:
    if n[0]>n[1] or (n[0]==n[1] and n[1]>n[2]):
        print(n[0]*3)
    else:
        print((str(int(n[0])+1))*3)
Buggy python submission (verdict: Runtime Error):
a=int(input())
b=int(input())
print((a-1)*(b-1))

Fixed submission:

a,b=map(int,input().split())
print((a-1)*(b-1))

Buggy python submission (verdict: Runtime Error):
print(((int(input()))-1) *((int(input()))-1) )

Fixed submission:

a,b=map(int,input().split())
print((a-1)*(b-1))
Buggy python submission (verdict: Runtime Error):
n=input()
s=0
for i in range(len(n)):
    s += n[i]
if int(n)%s == 0:
    print('Yes')
else:
    print('No')

Fixed submission:
n=input()
s=0
for i in range(len(n)):
    s += int(n[i])
if int(n)%s == 0:
    print('Yes')
else:
    print('No')
Buggy python submission (verdict: Runtime Error):

n=input()
if n < 1000:
    prnt('ABC')
else:
    print('ABD')

Fixed submission:

n=int(input())
if n < 1000:
    print('ABC')
else:
    print('ABD')
Buggy python submission (verdict: Runtime Error):
n=int(input())
d,x=map(int,input().split())
a=list(map(int,input().split('\n')))
b=[]
cnt=n
for i in range(n):
    b[i] = 1
    while b[i]<=d:
        b[i] += a[i]
        cnt += 1
print(cnt+x)

Fixed submission:
n=int(input())
d,x=map(int,input().split())
cnt=n
for i in range(n):
    a=int(input())
    b = a+1
    while b <= d:
        cnt += 1
        b += a
print(cnt+x)
Buggy python submission (verdict: Runtime Error):

X=input()
A=input()
B=input()
X -= A
Y = X % B
print(Y)

Fixed submission:
x,a,b = [int(input()) for i in range(3)]
print((x-a)%b)

Buggy python submission (verdict: Runtime Error):
a,b,c=[int(input()) for i in range(3)]
    print((a-b) % c)

Fixed submission:
x,a,b = [int(input()) for i in range(3)]
print((x-a)%b)

Buggy python submission (verdict: Runtime Error):
a,b,c=[int(input())for i in range(3)]
    print((a-b)%c)

Fixed submission:
x,a,b = [int(input()) for i in range(3)]
print((x-a)%b)

Buggy python submission (verdict: Runtime Error):
a,b,c=[int(input())for i in range(3)]
a-=b
a%=c
    print(a)


Fixed submission:
x,a,b = [int(input()) for i in range(3)]
print((x-a)%b)
Buggy python submission (verdict: Runtime Error):
a,b=map(int,input().split())
s=0
s += b
s += a*(10**len(b))
for i in range(320):
    if s==i*i:
        print(i)
        exit()


Fixed submission:
a,b=input().split()
s=0
s += int(b)
s += int(a)*(10**len(b))
for i in range(320):
    if s==i*i:
        print('Yes')
        exit()
print('No')

Buggy python submission (verdict: Runtime Error):
a,b=map(int,input().split())
s=0
s += b
s += b*(10**len(a))
for i in range(320):
    if s==i*i:
        print(i)
        exit()


Fixed submission:
a,b=input().split()
s=0
s += int(b)
s += int(a)*(10**len(b))
for i in range(320):
    if s==i*i:
        print('Yes')
        exit()
print('No')

Buggy python submission (verdict: Runtime Error):
a,b=map(int,input().split())
s=0
s += b
s += a*(10**len(a))
for i in range(320):
    if s==i*i:
        print(i)
        exit()


Fixed submission:
a,b=input().split()
s=0
s += int(b)
s += int(a)*(10**len(b))
for i in range(320):
    if s==i*i:
        print('Yes')
        exit()
print('No')

Buggy python submission (verdict: Runtime Error):
a,b=map(int,input().split())
s=0
s += b
s += a*(10*len(a))
for i in range(320):
    if s==i*i:
        print(i)
        exit()


Fixed submission:
a,b=input().split()
s=0
s += int(b)
s += int(a)*(10**len(b))
for i in range(320):
    if s==i*i:
        print('Yes')
        exit()
print('No')
Buggy python submission (verdict: Runtime Error):
n=int(input())
d=list(int(input()) for i in range(n))
cnt=0
st=100
l=[]
for i in range(n):
    if d<st:
        cnt += 1
        st = d
    else:
        l.append(cnt)
        st = 100
        cnt = 0
l.sort()
print(l[len(l)-1])

Fixed submission:
n=int(input())
k=[]
for i in range(n):
    d = int(input())
    k.append(d)
print(len(set(k)))

Buggy python submission (verdict: Runtime Error):
n=int(input())
d=list(int(input()) for i in range(n))
cnt=0
st=100
l=[]
for i in range(n):
    if d<st:
        cnt += 1
        st = d
    else:
        l.append(cnt)
        st = 100
print(max(l))

Fixed submission:
n=int(input())
k=[]
for i in range(n):
    d = int(input())
    k.append(d)
print(len(set(k)))