Harryxun/testdata huggingface dataset:
Buggy python submission (verdict: Runtime Error):
x, a, b = map(int, input().split())
if x < b - a:
  print("dangerous")
elif x <= b - a and 0 < x - (a - b):
  primt("safe")
elif 0 >= b - a:
  print("delicious")

Fixed submission:
x, a, b = map(int, input().split())
if a >= b:
    print('delicious')
elif a + x >= b:
    print('safe')
else:
    print('dangerous')

Buggy python submission (verdict: Runtime Error):
x, a, b = map(int, input().split())
if x < b - a:
  print("dangerous")
elif x == b - a:
  primt("safe")
elif x <= b - a and 0 <= a - b:
  print("delicious")

Fixed submission:
x, a, b = map(int, input().split())
if a >= b:
    print('delicious')
elif a + x >= b:
    print('safe')
else:
    print('dangerous')

Buggy python submission (verdict: Runtime Error):
x, a, b = map(int, input().split())
if x < b - a:
  print("dangerous")
elif x == b - a:
  primt("safe")
elif x <= b - a:
  print("delicious")


Fixed submission:
x, a, b = map(int, input().split())
if a >= b:
    print('delicious')
elif a + x >= b:
    print('safe')
else:
    print('dangerous')

Buggy python submission (verdict: Runtime Error):
x, a, b = map(int, input().split())
if x < b - a:
  print("dangerous")
elif x <= b - a:
  print("delicious")
else:
  primt("safe")

Fixed submission:
x, a, b = map(int, input().split())
if a >= b:
    print('delicious')
elif a + x >= b:
    print('safe')
else:
    print('dangerous')
Buggy python submission (verdict: Runtime Error):
a, b = int(input().split())
if a + b >= 10:
  print("error")
else:
  print(a + b)

Fixed submission:
a, b = map(int, input().split())
if a + b >= 10:
  print("error")
else:
  print(a + b)

Buggy python submission (verdict: Runtime Error):
a, b = int(input().split())
if a + b >= 10:
  print("error")
else:
  print(a + B)

Fixed submission:
a, b = map(int, input().split())
if a + b >= 10:
  print("error")
else:
  print(a + b)
Buggy python submission (verdict: Runtime Error):
a, b = map(int, input().split())
g1 = [1, 3, 5, 7, 8, 10, 12]
g2 = [4, 6, 9, 11]
g3 = [2]
if g1 in a and g1 in b:
  print("Yes")
elif g2 in a and g2 in b:
  print("Yes")
elif g3 in a and g3 in b:
  print("Yes")
else:
  print("No")
  

Fixed submission:
a, b = map(int, input().split())
g1 = [1, 3, 5, 7, 8, 10, 12]
g2 = [4, 6, 9, 11]
g3 = [2]
if a in g1  and b in g1:
  print("Yes")
elif a in g2  and b in g2:
  print("Yes")
elif a in g3  and b in g3:
  print("Yes")
else:
  print("No")
Buggy python submission (verdict: Runtime Error):
a, b, c = input().split().upper()
print((a[0], b[0], c[0]).sep())

Fixed submission:
a, b, c = input().split()
print((a[0] + b[0] + c[0]).upper())

Buggy python submission (verdict: Runtime Error):
a, b, c = input().split()
print((a[0], b[0], c[0]).sep())

Fixed submission:
a, b, c = input().split()
print((a[0] + b[0] + c[0]).upper())

Buggy python submission (verdict: Runtime Error):
a, b, c = map(str, input().split().upper())
print(a[0] + b[0] + c[0])

Fixed submission:
a, b, c = input().split()
print((a[0] + b[0] + c[0]).upper())

Buggy python submission (verdict: Runtime Error):
a, b, c = map(str, input().split().upper())
print(a[0] + b[0] + c[0])


Fixed submission:
a, b, c = input().split()
print((a[0] + b[0] + c[0]).upper())
Buggy python submission (verdict: Runtime Error):
A. B = map(int, input().split())
if A + B >= 24:
  print((A + B) - 24)
else:
  print(A + B)

Fixed submission:
A, B = map(int,input().split())
if A + B < 24:
  print(A + B)
else:
  print((A + B) - 24)
Buggy python submission (verdict: Runtime Error):
a = input()
t = input()
if a == "H" and t == "H":
  print("H")
elif a == "H" and t == "D":
  print("D")
elif a == "D" and t == "H":
  print("D")
elif a == "D" and t == "D"
  print("H")
else:
  pass

Fixed submission:
a, t = input().split()
if a == t:
  print("H")
else:
  print("D")

Buggy python submission (verdict: Runtime Error):
a = input()
t = input()
if a == "H" and t == "H":
  print("H")
elif a == "H" and t == "D":
  print("D")
elif a == "D" and t == "H":
  print("D")
else:
  pass

Fixed submission:
a, t = input().split()
if a == t:
  print("H")
else:
  print("D")

Buggy python submission (verdict: Runtime Error):
a = input()
t = input()
if a == t:
  print("H")
elif a != t :
  print("D")
else:
  pass

Fixed submission:
a, t = input().split()
if a == t:
  print("H")
else:
  print("D")

Buggy python submission (verdict: Runtime Error):
a,t = map(string, input().split())
if a == t:
  print("H")
elif a != t:
  print("D")

Fixed submission:
a, t = input().split()
if a == t:
  print("H")
else:
  print("D")

Buggy python submission (verdict: Runtime Error):
a,t = map(string, input().split())
if a == t:
  print("H")
elif a != t :
  print("D")

Fixed submission:
a, t = input().split()
if a == t:
  print("H")
else:
  print("D")
Buggy python submission (verdict: Runtime Error):
n = int(input())
x = 800*n
b = n%15
if b == 0:
  y = 200*b
print(x-y)

Fixed submission:
n = int(input())
x = 800*n
y = 200*(int(n/15))
print(x-y)
Buggy python submission (verdict: Runtime Error):
A, OP, B== input().split()
a= int(A)
b= int(B)
print(a+b if OP== "+" else a-b)


Fixed submission:
print(eval(input()))

Buggy python submission (verdict: Runtime Error):
A, B= map(int(input().split))
OP= input()
P= A + B
M= A - B
print(P if OP== + else M)

Fixed submission:
print(eval(input()))

Buggy python submission (verdict: Runtime Error):
A, X, B= map(int, input().split())
P= A + B
M= A - B
print(P if X== str(-) else M )

Fixed submission:
print(eval(input()))
Buggy python submission (verdict: Runtime Error):
c = input()
if c in [a, i, u, e, o]:
  print("vowel")
else:
  print("consonant")

Fixed submission:
c = input()
if c in ["a", "i", "u", "e", "o"]:
  print("vowel")
else:
  print("consonant")

Buggy python submission (verdict: Runtime Error):
c = input()
if c == "a", "i", "u", "e", "o":
  print("vowel")
else:
  print("consonant")

Fixed submission:
c = input()
if c in ["a", "i", "u", "e", "o"]:
  print("vowel")
else:
  print("consonant")
Buggy python submission (verdict: Runtime Error):
A, X, C= map(int,input().split())
print(A[0] + X[0] + C[0])

Fixed submission:
Atcoder, s, Contest= map(str, input().split())
print("A" + s[0] + "C")

Buggy python submission (verdict: Runtime Error):
c= list(map(int,input().split()))
print(str[1])

Fixed submission:
Atcoder, s, Contest= map(str, input().split())
print("A" + s[0] + "C")
Buggy python submission (verdict: Runtime Error):
candy=sorted(map(int,input().split()))
print("Yes" if candy[0]+candy[1]==candy[2] "No")

Fixed submission:
candy= sorted(map(int,input().split()))
print("Yes" if candy[0]+candy[1]== candy[2] else "No")

Buggy python submission (verdict: Runtime Error):
candy=sorted(map(int,input().split()))
print("Yes" if candy[0]+candy[1]=candy[2] "No")

Fixed submission:
candy= sorted(map(int,input().split()))
print("Yes" if candy[0]+candy[1]== candy[2] else "No")

Buggy python submission (verdict: Runtime Error):
candy=sorted(map(int,input().split()))
print("Yes" if candy[0]+candy[1]=candy[2])

Fixed submission:
candy= sorted(map(int,input().split()))
print("Yes" if candy[0]+candy[1]== candy[2] else "No")

Buggy python submission (verdict: Runtime Error):
A, B, C = [int(input()) for _ in range(3)]
if A + B == C or B + C == A or C + A == B:
  print("Yes")
else:
  print("No")

Fixed submission:
candy= sorted(map(int,input().split()))
print("Yes" if candy[0]+candy[1]== candy[2] else "No")
Buggy python submission (verdict: Runtime Error):
color = list(map(int,input().split))
print(len(set(color)))

Fixed submission:
color = list(map(int,input().split()))
print(len(set(color)))

Buggy python submission (verdict: Runtime Error):
color = list(map(int, input().split()))
print(len(set(color))

Fixed submission:
color = list(map(int,input().split()))
print(len(set(color)))

Buggy python submission (verdict: Runtime Error):
color = set(map(int, input().split))
print(len(color))

Fixed submission:
color = list(map(int,input().split()))
print(len(set(color)))

Buggy python submission (verdict: Runtime Error):
A, B C = set(map(int.input().split))
print(len(A, B, C))

Fixed submission:
color = list(map(int,input().split()))
print(len(set(color)))

Buggy python submission (verdict: Runtime Error):
a, b, c = [int(input()) for _ in range(3)]
if (a == b != c) or (b == c != a) or (c == a != b):
  print(2)
elif (a == b == c):
  print(1)
else:
  print(3)

Fixed submission:
color = list(map(int,input().split()))
print(len(set(color)))

Buggy python submission (verdict: Runtime Error):
a, b, c = [int(input()) for_in range(3)]
if a == b != c or b == c != a or c == a != b:
  print(2)
elif (a == b == c):
  print(1)
else:
  print(3)

Fixed submission:
color = list(map(int,input().split()))
print(len(set(color)))

Buggy python submission (verdict: Runtime Error):
a, b, c = [int(input()) for_in range(3)]
if (a == b != c) or (b == c != a) or (c == a != b):
  print(2)
elif (a == b == c):
  print(1)
else:
  print(3)

Fixed submission:
color = list(map(int,input().split()))
print(len(set(color)))
Buggy python submission (verdict: Runtime Error):
a, b, h = [int(input()) for _ i in range(3)]
print(int((a+b)*h/2))

Fixed submission:
a, b, h = [int(input()) for _ in range(3)]
print((a+b)*h//2)

Buggy python submission (verdict: Runtime Error):
a,b,h=[int(input()) for _ i in range(3)]
print((a+b)*h//2)

Fixed submission:
a, b, h = [int(input()) for _ in range(3)]
print((a+b)*h//2)

Buggy python submission (verdict: Runtime Error):
a,b,c=[int(input()) for _ i in range(3)]
print(int(a+b)*h/2)

Fixed submission:
a, b, h = [int(input()) for _ in range(3)]
print((a+b)*h//2)

Buggy python submission (verdict: Runtime Error):
a,b,c=[int(input()) for _ i in range(3)]
print((a+b)*h//2)

Fixed submission:
a, b, h = [int(input()) for _ in range(3)]
print((a+b)*h//2)

Buggy python submission (verdict: Runtime Error):
a,b,c=[int(input()) for_i in range(3)]
print((a+b)*h//2)

Fixed submission:
a, b, h = [int(input()) for _ in range(3)]
print((a+b)*h//2)
Buggy python submission (verdict: Runtime Error):
N = int(input())
K = int(input())
X = int(input())
Y = int(input())

total_price = ((k * X) + ((N - K) * Y))
print(total_price)

Fixed submission:
N=int(input())
K=int(input())
X=int(input())
Y=int(input())
 
a=K
b=N-K
c=N
 
if b>0:
	print(a*X+b*Y)
else:
	print(c*X)
Buggy python submission (verdict: Runtime Error):
N = int(input)
for total in N:
  print(N * (N + 1)/2)

Fixed submission:
N = int(input())
print(int(N * (N + 1) / 2))

Buggy python submission (verdict: Runtime Error):
N = int(input())
for total in N:
  (N += 1)
  print(N + (N + 1))

Fixed submission:
N = int(input())
print(int(N * (N + 1) / 2))
Buggy python submission (verdict: Runtime Error):
a, b, c = map(int, input().split())
if a == 5 and b == 7 and c = 5:
  print("YES")
else:
  print("NO")

Fixed submission:
a, b, c = map(int, input().split())
if a + b + c == 17:
  print("YES")
else:
  print("NO")

Buggy python submission (verdict: Runtime Error):
a = int(input())
b = int(input())
c = int(input())

if a == 5 and b == 7 and c == 5:
  print("YES")
else:
  print("NO")

Fixed submission:
a, b, c = map(int, input().split())
if a + b + c == 17:
  print("YES")
else:
  print("NO")

Buggy python submission (verdict: Runtime Error):
a, b, c = map(int, input().split())
if a == 5 and b == 7 and c = 5:
  print("Yes")
else:
  print("No")

Fixed submission:
a, b, c = map(int, input().split())
if a + b + c == 17:
  print("YES")
else:
  print("NO")

Buggy python submission (verdict: Runtime Error):
a = int(input())
b = int(input())
c = int(input())
if a　＋　b　＋　c　==　１７：
	print("YES")
else:
	print("NO")


Fixed submission:
a, b, c = map(int, input().split())
if a + b + c == 17:
  print("YES")
else:
  print("NO")
Buggy python submission (verdict: Runtime Error):
n, l = map(int, input().split())
s = list([input() for i in ramge(n)])
s1 = s.sort()
print("".join(s1))

Fixed submission:
n, l = map(int, input().split())
s = [input() for i in range(n)]
s.sort()
print("".join(s))

Buggy python submission (verdict: Runtime Error):
n, l = map(int, input().split())
s = [input() for i in ramge(n)]
s1 = s.sort()
print("".join(s1))

Fixed submission:
n, l = map(int, input().split())
s = [input() for i in range(n)]
s.sort()
print("".join(s))

Buggy python submission (verdict: Runtime Error):
n, l = int(input())
s = [int(input()) for i in range(n) ]
print(sorted(s))

Fixed submission:
n, l = map(int, input().split())
s = [input() for i in range(n)]
s.sort()
print("".join(s))
Buggy python submission (verdict: Runtime Error):
for i in str(n):
    if i == str(7):
        print('Yes')
        break
    else:
        print('No')

Fixed submission:
n =int(input())

c = 1
for i in str(n):
    if i == str(7):
        print('Yes')
        c = 0
        break
    else:
        pass
if c != 0:
    print('No')
Buggy python submission (verdict: Runtime Error):
s = input()
t = input()

if s[0] == t[0] and s[1] == t[1] and s[2] == t[2]:
    print(3)
elif (s[0] == t[0] and s[1] == t[1]) or (s[1] == t[1] and s[2] == t[2]) or (s[0] == t[0] and s[3] == t[3]):
    print(2)
elif s[0] == t[0] or s[1] == t[1] or s[2] == t[2]:
    print(1)
else:
    print(0)

Fixed submission:
s = input()
t = input()

ans = 0
for i in range(3):
    if s[i] == t[i]:
        ans += 1
print(ans)
Buggy python submission (verdict: Runtime Error):
a,b = map(int,input().split())

ans = 0

while b > 0:
	if b - ( a - 1 ) > a:
    	b -= a - 1
        ans += 1
    else:
        b -= a
        ans += 1

print(ans)

Fixed submission:
a,b = map(int,input().split())

ans = 0
out = 1

while out < b:
    out -= 1
    out += a
    ans += 1

print(ans)
Buggy python submission (verdict: Runtime Error):
#include <bits/stdc++.h>
using namespace std;
 
int main() {
  int n, k;  
  cin >> n >> k ;

  int ans = 0;
  int x;
  for (int i=0; i<n; i++) {
    cin >> x;
    ans += min(x*2, (k-x)*2);
  }

  cout << ans << endl;
}


Fixed submission:
n = int(input())
k = int(input())
x = list(map(int, input().split()))
ans = 0

for i in x:
    ans += min(i*2, (k-i)*2)
    
print(ans)
Buggy python submission (verdict: Time Limit Exceeded):
import math
import numpy as np

K = int(input())

gcdSum = 0

myArr = np.zeros((K, K), dtype=int)

for iIndx in range(K):
    for jIndx in range(K):
        myArr[iIndx, jIndx] = math.gcd(iIndx+1, jIndx+1)

for iIndx in range(K):
    for jIndx in range(K):
        presGcd = myArr[iIndx, jIndx]
        for kIndx in range(K):
            gcdSum += myArr[presGcd-1, kIndx]

print(gcdSum)

Fixed submission:
import math

K = int(input())

gcdSum = 0
myDict = {}

for iIndx in range(1, K+1):
    for jIndx in range(1, iIndx+1):
        presGcd = math.gcd(iIndx, jIndx)
        if (presGcd in list(myDict.keys())) and (iIndx == jIndx):
            myDict[presGcd] += 1
        elif (presGcd in list(myDict.keys())) and (iIndx != jIndx):
            myDict[presGcd] += 2
        elif (presGcd not in list(myDict.keys())) and (iIndx == jIndx):
            myDict[presGcd] = 1
        elif (presGcd not in list(myDict.keys())) and (iIndx != jIndx):
            myDict[presGcd] = 2
        else:
            print('error')

for kIndx in range(1, K+1):
    for keyItem in list(myDict.keys()):
        gcdSum += math.gcd(keyItem, kIndx) * myDict[keyItem]

print(gcdSum)

Buggy python submission (verdict: Time Limit Exceeded):
import math

K = int(input())

gcdSum = 0

for iIndx in range(1, K+1):
    for jIndx in range(1, K+1):
        for kIndx in range(1, K+1):
            gcdSum += math.gcd(math.gcd(iIndx, jIndx), kIndx)

print(gcdSum)

Fixed submission:
import math

K = int(input())

gcdSum = 0
myDict = {}

for iIndx in range(1, K+1):
    for jIndx in range(1, iIndx+1):
        presGcd = math.gcd(iIndx, jIndx)
        if (presGcd in list(myDict.keys())) and (iIndx == jIndx):
            myDict[presGcd] += 1
        elif (presGcd in list(myDict.keys())) and (iIndx != jIndx):
            myDict[presGcd] += 2
        elif (presGcd not in list(myDict.keys())) and (iIndx == jIndx):
            myDict[presGcd] = 1
        elif (presGcd not in list(myDict.keys())) and (iIndx != jIndx):
            myDict[presGcd] = 2
        else:
            print('error')

for kIndx in range(1, K+1):
    for keyItem in list(myDict.keys()):
        gcdSum += math.gcd(keyItem, kIndx) * myDict[keyItem]

print(gcdSum)
Buggy python submission (verdict: Time Limit Exceeded):
def dfs(inParam, digits, lunlunCount, lunlun):
    if len(inParam) != digits:
        if int(inParam[len(inParam)-1]) == 0:
            nextNumList = [0, 1]
        elif int(inParam[len(inParam)-1]) == 9:
            nextNumList = [8, 9]
        else:
            nextNum = int(inParam[len(inParam)-1])
            nextNumList = [nextNum-1, nextNum, nextNum+1]
        
        for item in nextNumList:
            myTupp = dfs(inParam+str(item), digits, lunlunCount, lunlun)
            lunlunCount = myTupp[0]
            if myTupp[2] == 'e':
                return myTupp
        
        return myTupp
    
    else:
        lunlunCount += 1
        state = 'c'

        if lunlunCount == lunlun:
            state = 'e'
            print(inParam)

        return (lunlunCount, inParam, state)

K = int(input())

mylunlun = 0
mydigits = 1
while mylunlun != K:
    for indx in range(1, 10):
        mylunlun, lunlunNumber, _ = dfs(str(indx), mydigits, mylunlun, K)
        # if mylunlun == K:
        #     break
    
    if mylunlun == K:
        break

    mydigits += 1


Fixed submission:
def dfs(inParam, digits, lunlunCount, lunlun):
    if len(inParam) != digits:
        if int(inParam[len(inParam)-1]) == 0:
            nextNumList = [0, 1]
        elif int(inParam[len(inParam)-1]) == 9:
            nextNumList = [8, 9]
        else:
            nextNum = int(inParam[len(inParam)-1])
            nextNumList = [nextNum-1, nextNum, nextNum+1]
        
        for item in nextNumList:
            myTupp = dfs(inParam+str(item), digits, lunlunCount, lunlun)
            lunlunCount = myTupp[0]
            if myTupp[2] == 'e':
                return myTupp
        
        return myTupp
    
    else:
        lunlunCount += 1
        state = 'c'

        if lunlunCount == lunlun:
            state = 'e'
            print(inParam)

        return (lunlunCount, inParam, state)

K = int(input())

mylunlun = 0
mydigits = 1
while mylunlun != K:
    for indx in range(1, 10):
        mylunlun, lunlunNumber, _ = dfs(str(indx), mydigits, mylunlun, K)
        if mylunlun == K:
            break
    
    if mylunlun == K:
        break

    mydigits += 1
Buggy python submission (verdict: Time Limit Exceeded):
X, Y, A, B, C = map(int, input().split())

pList = list(map(int, input().split()))
qList = list(map(int, input().split()))
rList = list(map(int, input().split()))

pList.sort(reverse=True)
qList.sort(reverse=True)
rList.sort(reverse=True)

pList = pList[:X]
qList = qList[:Y]

value = 0

for indx in range(X+Y):
    if (pList[0] >= qList[0]) and (pList[0] >= rList[0]):
        value += pList[0]
        pList.pop(0)

        if len(pList) == 0:
            pList.append(-1)

    elif (qList[0] > pList[0]) and (qList[0] > rList[0]):
        value += qList[0]
        qList.pop(0)

        if len(qList) == 0:
            qList.append(-1)

    else:
        value += rList[0]
        rList.pop(0)

        if len(rList) == 0:
            rList.append(-1)


print(value)


Fixed submission:
X, Y, A, B, C = map(int, input().split())

pList = list(map(int, input().split()))
qList = list(map(int, input().split()))
rList = list(map(int, input().split()))

pList.sort(reverse=True)
qList.sort(reverse=True)
rList.sort(reverse=True)

pList = pList[:X]
qList = qList[:Y]

appleList = pList + qList + rList
appleList.sort(reverse=True)
appleList = appleList[:X+Y]

print(sum(appleList))
Buggy python submission (verdict: Runtime Error):
a, b, c = map(int, input().split(" "))

if ((a == b) and (b != c)) or
   ((b == c) and (c != a)) or
   ((c == a) and (a != b)):
  print("Yes")
else:
  print("No")

Fixed submission:
a, b, c = map(int, input().split(" "))
 
if (((a == b) and (b != c)) or 
    ((b == c) and (c != a)) or
    ((c == a) and (a != b))):
  print("Yes")
else:
  print("No")
Buggy python submission (verdict: Runtime Error):
N = int(input())
inList = list(map(int, input().aplit(" ")))

evenList = list([])

for item in inList:
  if item % 2 == 0:
    evenList.append(item)

jdgList = list([])

for evenItem in evenList:
  if ((evenItem % 3) == 0) or ((evenItem % 5) == 0):
    jdgList.append(evenItem)

if len(jdgList) == len(evenList):
  print("APPROVED")
else:
  print("DENIED")

Fixed submission:
N = int(input())
inList = list(map(int, input().split(" ")))
 
evenList = list([])
 
for item in inList:
  if item % 2 == 0:
    evenList.append(item)

jdgList = list([])
 
for evenItem in evenList:
  if ((evenItem % 3) == 0) or ((evenItem % 5) == 0):
    jdgList.append(evenItem)

if len(jdgList) == len(evenList):
  print("APPROVED")
else:
  print("DENIED")
Buggy python submission (verdict: Time Limit Exceeded):
N = int(input())

strList = list([])

for i in range(N):
  strList.append(str(input()))

strDict = {}

for item in strList:
  if item not in strDict.keys():
    strDict[item] = 1
  else:
    strDict[item] += 1

maxList = list([])

for strKeys in strDict.keys():
  if strDict[strKeys] == max(strDict.values()):
    maxList.append(strKeys)

for srtedItem in sorted(maxList):
  print(srtedItem)

Fixed submission:
N = int(input())

strList = list([])

for i in range(N):
  strList.append(str(input()))

strDict = {}

for item in strList:
  if item not in strDict.keys():
    strDict[item] = 1
  else:
    strDict[item] += 1

maxList = list([])
maxNum = max(strDict.values())

for strKeys in strDict.keys():
  if strDict[strKeys] == maxNum:
    maxList.append(strKeys)

for srtedItem in sorted(maxList):
  print(srtedItem)

Buggy python submission (verdict: Runtime Error):
N = input()

strList = list([])

for i in range(N):
  strList.append(str(input()))

strDict = {}

for item in strList:
  if item not in strDict.keys():
    strDict[item] = 1
  else:
    strDict[item] += 1

maxList = list([])

for strKeys in strDict.keys():
  if strDict[strKeys] == max(strDict.items()):
    maxList.append(strKeys)

print(maxList.sort())

Fixed submission:
N = int(input())

strList = list([])

for i in range(N):
  strList.append(str(input()))

strDict = {}

for item in strList:
  if item not in strDict.keys():
    strDict[item] = 1
  else:
    strDict[item] += 1

maxList = list([])
maxNum = max(strDict.values())

for strKeys in strDict.keys():
  if strDict[strKeys] == maxNum:
    maxList.append(strKeys)

for srtedItem in sorted(maxList):
  print(srtedItem)
Buggy python submission (verdict: Time Limit Exceeded):
N, K = map(int, input().split())
inList = list(map(int, input().split()))

maxNum = -1

for indx in range(N - (K - 1)):
  maxNum = max(sum(inList[indx: indx + K]), maxNum)

print((maxNum + K) / 2)

Fixed submission:
N, K = map(int, input().split())
inList = list(map(int, input().split()))

lastSum = sum(inList[0: K])
maxNum = lastSum

for indx in range(1, N - (K - 1)):
  maxNum = max(lastSum - inList[indx-1] + inList[indx+K-1], maxNum)
  lastSum = lastSum - inList[indx-1] + inList[indx+K-1]

print((maxNum + K) / 2)
Buggy python submission (verdict: Runtime Error):
i j = map(int, input().split(" "))

if i*j % 2 == 0:
  print("Even")
else:
  print("Odd")

Fixed submission:
i, j = map(int, input().split(" "))

if (i * j) % 2 == 0:
  print("Even")
else:
  print("Odd")
Buggy python submission (verdict: Runtime Error):
s = str(input())

count = 0

for i in range(len(s)):
  if s[i] == "1":
    count++

print(count)

Fixed submission:
s = str(input())

count = 0

for i in range(len(s)):
  if s[i] == "1":
    count += 1

print(count)
Buggy python submission (verdict: Runtime Error):
i = input()
ans = 'Yes' if '7' in 1 else 'No'
print(ans)

Fixed submission:
i = input()
ans = 'Yes' if '7' in i else 'No'
print(ans)
Buggy python submission (verdict: Runtime Error):
import math
n = int(input())
print(math.factorial(n) / (pow(10, 9) + 7))


Fixed submission:
import math
n = int(input())
b = pow(10, 9) + 7
print(math.factorial(n) % b)
Buggy python submission (verdict: Runtime Error):
n=input()
if n.count("7")!=0:
  
  print("Yes)
else:
  print("No")

Fixed submission:
n=input()
if n.count("7")!=0:
    print("Yes")
else:
    print("No")