Harryxun/testdata huggingface dataset:
Buggy python submission (verdict: Runtime Error):
///                ..:: In The Name Of God ::..
#include <algorithm>
#include <cstdio>
#include <iostream>
#include <list>
#include <queue>
#include <string>
#include <vector>
using namespace std;
//配列の要素数は　sizeof(ar)/sizeof(ar[0]) で求める
int N,M;
double X;
signed main(){
    cin.tie(0);
    cout.tie(0);
    ios::sync_with_stdio(false);
    cin >> N;
    X = ceil(N/(1.08));
    M = floor(X*(1.08));
    if(M == N){
        cout << X;
    }
    else{
        cout << ":(";
    }
}   

Fixed submission:
import math
from math import ceil, floor
N = int(input())
X = ceil(N/(1.08))
M = floor(X*1.08)

if M==N:
    print(X)
else:
    print(":(")

Buggy python submission (verdict: Runtime Error):
import math
N = int(input())
X = floor(float(N/(1.08)))

if X==N:
    print(X)
else:
    print(":(")


Fixed submission:
import math
from math import ceil, floor
N = int(input())
X = ceil(N/(1.08))
M = floor(X*1.08)

if M==N:
    print(X)
else:
    print(":(")

Buggy python submission (verdict: Runtime Error):
import math
N = int(input())
X = floor(float(N/(1.08)))

if X==N:
    print(X)
else:
    print(":(")


Fixed submission:
import math
from math import ceil, floor
N = int(input())
X = ceil(N/(1.08))
M = floor(X*1.08)

if M==N:
    print(X)
else:
    print(":(")
Buggy python submission (verdict: Runtime Error):
x = input()
flag = 0

for i in (0,4):
    if x[i] == x[i+1]:
        flag += 1
    else :
        flag += 0

if flag == 0:
    print("Good")
else :
    print("Bad")

Fixed submission:
x = input()
flag = 0

for i in range(0,3):
    if x[i] == x[i+1]:
        flag += 1
    else :
        flag += 0

if flag == 0:
    print("Good")
else :
    print("Bad")

Buggy python submission (verdict: Runtime Error):
x = (input())
flag = 0

for i in (0,4):
    if x[i] == x[i+1]:
        flag += 1
    else :
        flag += 0

if flag == 0:
    print("Good")
else :
    print("Bad")

Fixed submission:
x = input()
flag = 0

for i in range(0,3):
    if x[i] == x[i+1]:
        flag += 1
    else :
        flag += 0

if flag == 0:
    print("Good")
else :
    print("Bad")

Buggy python submission (verdict: Runtime Error):
x = (input())
int flag = 0

for i in (0,4)
    if x[i] == x[i+1]
        flag += 1
    else 
        flag += 0

if flag == 0
    print('Good')
else print('Bad')

Fixed submission:
x = input()
flag = 0

for i in range(0,3):
    if x[i] == x[i+1]:
        flag += 1
    else :
        flag += 0

if flag == 0:
    print("Good")
else :
    print("Bad")
Buggy python submission (verdict: Runtime Error):
A, B, C, X = int(input())
ans = 0
for i in range(0,A+1):
    for j in range(0,B+1):
        for k in range(0,C+1):
            sum = 500 * i + 100 * j + 50 * k
            if sum == X:
                ans += 1

print(ans)

Fixed submission:
A = int(input())
B = int(input())
C = int(input())
X = int(input())
ans = 0
for i in range(0,A+1):
    for j in range(0,B+1):
        for k in range(0,C+1):
            sum = 500 * i + 100 * j + 50 * k
            if sum == X:
                ans += 1

print(ans)
Buggy python submission (verdict: Runtime Error):
N = int(input().split())
T = list(map(int,input().split()))
M = int(input().split())
P_X = [list(map(int, input().split())) for i in range(M)]

s = sum(T)
for i in range(M):
    print(s-T[i-1][0]+T[i-1][1])

Fixed submission:
N = int(input())
T = list(map(int,input().split()))
M = int(input())

s = sum(T)
for i in range(M):
    P,X = map(int, input().split())
    print(s-T[P-1]+X)
Buggy python submission (verdict: Time Limit Exceeded):
n = int(input())
vals = list(map(lambda v: int(v), input().split()))
i = 0
sum = 1

while (i < len(vals)):
  sum = sum * vals[i]
  i = i + 1

if (sum > 10e17):
  print(-1)
  exit()

print(sum)

Fixed submission:
n = int(input())
vals = list(map(lambda v: int(v), input().split()))
vals.sort(reverse=True)
i = 0
sum = 1

if (0 in vals):
  print(0)
  exit()

while (i < len(vals)):
  sum = sum * vals[i]
  if (sum > 10e17):
    print(-1)
    exit()
  i = i + 1

print(sum)
Buggy python submission (verdict: Runtime Error):
n = int(input())
xy = []
pq = {}

for i in range(n):
    (x, y) = list(map(int, input().split()))
    xy = xy + [(x, y)]
    for (x_p, y_p) in xy:
        if (x-x_p, y-y_p) != (0, 0):
            if (x-x_p, y-y_p) in pq.keys():
                pq[(x-x_p, y-y_p)] = pq[(x-x_p, y-y_p)] + 1
            else:
                pq[(x-x_p, y-y_p)] = 1
print(n - max([1, max(pq.values())]))

Fixed submission:
n = int(input())
xy = [tuple(map(int, input().split())) for _ in range(n)]
pq = {}

if n==1:
    print(1)
    exit(0)

for (x, y) in xy:
    for (a, b) in xy:
        if (x, y) != (a, b):
            if (x-a, y-b) in pq.keys():
                pq[(x-a, y-b)] = pq[(x-a, y-b)] + 1
            else:
                pq[(x-a, y-b)] = 1

print(n - max(pq.values()))

Buggy python submission (verdict: Runtime Error):
n = int(input())
list = []
submap = {}
scmap = {}
for i in range(n):
    a, b = map(int, input().split())
    list = list + [(a,b)]
    for (x, y) in list:
        if (a-x, b-y) != (0, 0):
            if (a-x, b-y) in submap.keys():
                submap[(a-x, b-y)] = submap[(a-x, b-y)] + 1
            else:
                submap[(a-x, b-y)] = 1
(k, l) = max(submap, key=submap.get)

c = 0
while len(list) > 0:
    (x, y) = list[0]
    c = c + 1
    list.remove((x, y))
    while (x + k, y + l) in list:
        list.remove((x + k, y + l))
        (x, y) = (x + k, y + l)
print(c)

Fixed submission:
n = int(input())
xy = [tuple(map(int, input().split())) for _ in range(n)]
pq = {}

if n==1:
    print(1)
    exit(0)

for (x, y) in xy:
    for (a, b) in xy:
        if (x, y) != (a, b):
            if (x-a, y-b) in pq.keys():
                pq[(x-a, y-b)] = pq[(x-a, y-b)] + 1
            else:
                pq[(x-a, y-b)] = 1

print(n - max(pq.values()))
Buggy python submission (verdict: Runtime Error):
n = int(input())
a_list = [int(x) for x in input().split()]

if 0 in a_list:
  print(0)
  

else:
  flg = True
  num = 1
  for a in a_list:
    num *= a
    if num > 1E18:
      print(-1)
      flg = False
      break

if flg:
  print(num)

Fixed submission:
n = int(input())
a_list = [int(x) for x in input().split()]

if 0 in a_list:
  print(0)
  
else:
  flg = True
  num = 1
  for a in a_list:
    num *= a
    if num > 1E18:
      print(-1)
      flg = False
      break

  if flg:
    print(num)

Buggy python submission (verdict: Time Limit Exceeded):
n = int(input())
a_list = [int(x) for x in input().split()]

if 0 in a_list:
  print(0)
  
else:
  num = 1
  for a in a_list:
    num *= a
  if num > 1E18:
    print(-1)
  else:
  	print(num)

Fixed submission:
n = int(input())
a_list = [int(x) for x in input().split()]

if 0 in a_list:
  print(0)
  
else:
  flg = True
  num = 1
  for a in a_list:
    num *= a
    if num > 1E18:
      print(-1)
      flg = False
      break

  if flg:
    print(num)
Buggy python submission (verdict: Runtime Error):
n = int(input())
a_list = [int(x) for x in input().split()]

node = 1
flg = False
node_list = [node]

for i in range(len(a_list)-1):
  num = a_list[i]
  next = node-num
  if next < 0:
    flg = True
    break
  node = next*2
  node_list.append(node)

if node - a_list[-1] < 0:
  flg = True

diff = a_list[-1]
res_list = [a_list[-1]]
for i in range(len(a_list)-2,-1,-1):
  v = node_list[i] - a_list[i] # 枝の数
  diff = min(diff,v) + a_list[i]
  res_list.append(diff)

if flg:
  print(-1)
else:
  print(sum(res_list))

Fixed submission:
n = int(input())
a_list = [int(x) for x in input().split()]

node = 1
flg = False
node_list = [node]

for i in range(len(a_list)-1):
  num = a_list[i]
  next = node-num
  if next < 0:
    flg = True
    break
  node = next*2
  node_list.append(node)

if node - a_list[-1] < 0:
  flg = True
else:
  diff = a_list[-1]
  res_list = [a_list[-1]]
  for i in range(len(a_list)-2,-1,-1):
    v = node_list[i] - a_list[i] # 枝の数
    diff = min(diff,v) + a_list[i]
    res_list.append(diff)

if flg:
  print(-1)
else:
  print(sum(res_list))

Buggy python submission (verdict: Runtime Error):
n = int(input())
a_list = [int(x) for x in input().split()]

node = 1
sum_node = 1
flg = False
node_list = [node]

for i in range(len(a_list)-1):
  num = a_list[i]
  next = node-num
  if next < 0:
    flg = True
    break
  node = next*2
  node_list.append(node)
  sum_node += node
  
diff = node - a_list[-1]
if diff < 0:
  flg = True

diff = a_list[-1]
res_list = [a_list[-1]]
for i in range(len(a_list)-2,-1,-1):
  v = node_list[i] - a_list[i] # 枝の数
  diff = min(diff,v) 
  res_list.append(diff+a_list[i])
  diff = diff + a_list[i]

if flg:
  print(-1)
else:
  print(sum(res_list))

Fixed submission:
n = int(input())
a_list = [int(x) for x in input().split()]

node = 1
flg = False
node_list = [node]

for i in range(len(a_list)-1):
  num = a_list[i]
  next = node-num
  if next < 0:
    flg = True
    break
  node = next*2
  node_list.append(node)

if node - a_list[-1] < 0:
  flg = True
else:
  diff = a_list[-1]
  res_list = [a_list[-1]]
  for i in range(len(a_list)-2,-1,-1):
    v = node_list[i] - a_list[i] # 枝の数
    diff = min(diff,v) + a_list[i]
    res_list.append(diff)

if flg:
  print(-1)
else:
  print(sum(res_list))
Buggy python submission (verdict: Time Limit Exceeded):
import math
from functools import reduce

def gcd(*numbers):
    return reduce(math.gcd, numbers)

k = int(input())
num = 0
for a in range(1,k+1):
    for b in range(1,k+1):
        for c in range(1,k+1):
            num += gcd(a,b,c)

print(num)

Fixed submission:
import math
from functools import reduce

def gcd(*numbers):
    return reduce(math.gcd, numbers)

k = int(input())
num = 0
for a in range(1,k+1):
    for b in range(a,k+1):
        for c in range(b,k+1):
          x = gcd(a,b,c)
          bai = sum([a==b,b==c,a==c])
          if bai == 0:
            num += x*6
          elif bai == 1:
            num += x*3
          else:
            num += x
            
print(num)
Buggy python submission (verdict: Time Limit Exceeded):
n = int(input())
s = input()

num = 0
for i in range(0,n):
  for j in range(i+1,n):
    if s[i]==s[j]:
      continue
    for k in range(j+1,n):
      if s[i]!= s[k] and s[j]!=s[k] and (j-i)!=(k-j):
        num += 1
print(num)

Fixed submission:
n = int(input())
s = input()

r_cnt = s.count('R')
g_cnt = s.count('G')
b_cnt = s.count('B')

total = r_cnt*g_cnt*b_cnt

for i in range(0,n):
  for j in range(1,n):
    if i+(2*j)>=n:
      break
    if s[i]!=s[i+j] and s[i+j]!=s[i+2*j] and s[i]!=s[i+2*j]:
      total += -1

print(total)
Buggy python submission (verdict: Time Limit Exceeded):
n,a,b = (int(x) for x in input().split())
c = 0
b_flg = True
while True:
  if n <= 0:
    break
  if b_flg:
    n -= a
    c += a
    if n <= 0:
      c += n
    b_flg = False
  else:
    n -= b
    b_flg = True
print(c)



Fixed submission:
n,a,b = (int(x) for x in input().split())

count = (int(n/(a+b)))*a
count += min(n%(a+b),a)
print(count)
Buggy python submission (verdict: Time Limit Exceeded):
import collections
import copy

def prime_factorize(n):
    a = []
    while n % 2 == 0:
        a.append(2)
        n //= 2
    f = 3
    while f * f <= n:
        if n % f == 0:
            a.append(f)
            n //= f
        else:
            f += 2
    if n != 1:
        a.append(n)
    return a

x = int(input())
master_c = prime_factorize(x)
if len(master_c) == 1:
    print(x-1)
else:
    min_num = x-1
    for i in range(2,int(x/2)):
        if x % i == 0:
            num = int(i+(x/i)-2)
            if num < min_num:
                min_num = num
    print(min_num)

Fixed submission:
import math
x = int(input())
x_sqrt = int(math.sqrt(x))

min_num = x-1
for i in range(2,x_sqrt+2):
    if x % i == 0:
        num = i+int(x/i)-2
        if num < min_num:
            min_num = num
print(min_num)
Buggy python submission (verdict: Time Limit Exceeded):
import bisect
n = int(input())
l_li = [int(x) for x in input().split()]
l_li.sort()

count = 0
  
for i in range(n):
  for j in range(i+1,n):
    wa = l_li[i] + l_li[j]
    target = l_li[j+1:]
    count += bisect.bisect_left(target, wa)
    
print(count)

Fixed submission:
import bisect
n = int(input())
l_li = [int(x) for x in input().split()]
l_li.sort()

count = 0
  
for i in range(n):
  for j in range(i+1,n):
    wa = l_li[i] + l_li[j]
    count += bisect.bisect_left(l_li, wa) - j - 1
    
print(count)

Buggy python submission (verdict: Time Limit Exceeded):
n = int(input())
l_li = [int(x) for x in input().split()]
l_li.sort()

count = 0

for i in range(n):
  for j in range(i+1,n):
    wa = l_li[i] + l_li[j]
    for k in range(j+1,n):
      if l_li[k] >= wa:
        break
      count += 1
print(count)

Fixed submission:
import bisect
n = int(input())
l_li = [int(x) for x in input().split()]
l_li.sort()

count = 0
  
for i in range(n):
  for j in range(i+1,n):
    wa = l_li[i] + l_li[j]
    count += bisect.bisect_left(l_li, wa) - j - 1
    
print(count)

Buggy python submission (verdict: Time Limit Exceeded):
n = int(input())
l_li = [int(x) for x in input().split()]

count = 0

for i in range(n):
  for j in range(i+1,n):
    a = l_li[i]
    b = l_li[j]
    wa = a + b
    sa = a - b
    if sa < 0:
      sa = -1 * sa
    target = l_li[j+1:]
    count += sum([sa<x<wa for x in target])
print(count)

Fixed submission:
import bisect
n = int(input())
l_li = [int(x) for x in input().split()]
l_li.sort()

count = 0
  
for i in range(n):
  for j in range(i+1,n):
    wa = l_li[i] + l_li[j]
    count += bisect.bisect_left(l_li, wa) - j - 1
    
print(count)

Buggy python submission (verdict: Time Limit Exceeded):
n = int(input())
l_li = [int(x) for x in input().split()]

count = 0

for i in range(n):
  for j in range(i+1,n):
    a = l_li[i]
    b = l_li[j]
    wa = a + b
    sa = a - b
    if sa < 0:
      sa = -1 * sa
    for k in range(j+1,n):
      c = l_li[k]
      if c <= sa or c >= wa:
        continue
      count += 1
print(count)

Fixed submission:
import bisect
n = int(input())
l_li = [int(x) for x in input().split()]
l_li.sort()

count = 0
  
for i in range(n):
  for j in range(i+1,n):
    wa = l_li[i] + l_li[j]
    count += bisect.bisect_left(l_li, wa) - j - 1
    
print(count)
Buggy python submission (verdict: Time Limit Exceeded):
n,k,q = (int(i) for i in input().split())  
a = []
for i in range(q):
    a.append(int(input()))

score = [k for _ in range(n)]

for i in range(len(a)):
    clear_num = a[i]-1
    for j in range(n):
        if j != clear_num:
             score[j] += -1

for j in range(n):
    if score[j] > 0:
        print('Yes')
    else:
        print('No')



Fixed submission:
n,k,q = (int(i) for i in input().split())  
a = []
for i in range(q):
    a.append(int(input()))

score = [0 for _ in range(n)]

for i in range(len(a)):
    clear_num = a[i]-1
    score[clear_num] += 1


for j in range(n):
    if k + score[j] - q > 0:
        print('Yes')
    else:
        print('No')
Buggy python submission (verdict: Time Limit Exceeded):
def insertion_sort(array):
    n = array[0]
    for i in range(1, len(array)):
        tmp = array[i]
        if array[i] <= n :
            break
        else:
            array[i-1] = tmp
            array[i] = n
            
    return array

n,m = (int(i) for i in input().split()) 
a = [int(i) for i in input().split()]
a.sort(reverse=True)
for i in range(m):
    down = a[0]
    a.remove(down)
    a.insert(0,down//2)
    a = insertion_sort(a)
    
print(sum(a))






Fixed submission:
n,m = (int(i) for i in input().split()) 
a = [int(i) for i in input().split()]
b = []

a.sort(reverse=True)

for i in range(m):
    if i == 0:
        down = a[0]
        a.remove(down)
        b.append(down//2)
    else:
        if a != [] and a[0] >= b[0]:
            down = a[0]
            a.remove(down)
        else:
            down = b[0]
            b.remove(down)
        b.append(down//2)
    
print(sum(a)+sum(b))

Buggy python submission (verdict: Time Limit Exceeded):
n,m = (int(i) for i in input().split()) 
a = [int(i) for i in input().split()]
a.sort(reverse=True)
for i in range(m):
    down = a[0]
    a.remove(down)
    a.append(down//2)
    a.sort(reverse=True)
    
print(sum(a))

Fixed submission:
n,m = (int(i) for i in input().split()) 
a = [int(i) for i in input().split()]
b = []

a.sort(reverse=True)

for i in range(m):
    if i == 0:
        down = a[0]
        a.remove(down)
        b.append(down//2)
    else:
        if a != [] and a[0] >= b[0]:
            down = a[0]
            a.remove(down)
        else:
            down = b[0]
            b.remove(down)
        b.append(down//2)
    
print(sum(a)+sum(b))

Buggy python submission (verdict: Time Limit Exceeded):
n,m = (int(i) for i in input().split()) 
a = [int(i) for i in input().split()]

for i in range(m):
    down = max(a)
    a.remove(down)
    a.append(down//2)
    
print(sum(a))

Fixed submission:
n,m = (int(i) for i in input().split()) 
a = [int(i) for i in input().split()]
b = []

a.sort(reverse=True)

for i in range(m):
    if i == 0:
        down = a[0]
        a.remove(down)
        b.append(down//2)
    else:
        if a != [] and a[0] >= b[0]:
            down = a[0]
            a.remove(down)
        else:
            down = b[0]
            b.remove(down)
        b.append(down//2)
    
print(sum(a)+sum(b))
Buggy python submission (verdict: Time Limit Exceeded):
n = int(input())
line2 = input().split()
h_list = [int(x) for x in line2]
 
max_count = 0
size = len(h_list)

for i in range(size):
    now = h_list[i]
    count = 0
    for j in range(i+1,size):
        if now >= h_list[j]:
            count += 1
            now = h_list[j]
        else:
            break
        
    if max_count < count:
        max_count = count

print(max_count)

Fixed submission:
n = int(input())
line2 = input().split()
h_list = [int(x) for x in line2]
 
max_count = 0
size = len(h_list)

i = 0
while True: 
    if i == size-1:
        break
    now = h_list[i]
    count = 0
    for j in range(i+1,size):
        if now >= h_list[j]:
            count += 1
            now = h_list[j]
        else:
            break
    if max_count < count:
        max_count = count
        
    if max_count >= size - i:
        break
        
    i = j
    
print(max_count)
Buggy python submission (verdict: Time Limit Exceeded):
n = int(input())

sum = 0

for i in range(n):
    sum += i
    
print(sum)

Fixed submission:
n = int(input())
    
print(int((n*(n-1))//2))
Buggy python submission (verdict: Time Limit Exceeded):
import sys

def main():
    n = int(input())
    limit = pow(10,18)
    readStr = input()
    flds = readStr.split(" ")
    res = 1
    for i in range(n):
        if flds[i] == 0:
            res = 0
            break
        res *= int(flds[i])

    if res > limit:
        res = -1
    print(res)

if __name__ == "__main__":
    main()


Fixed submission:
import sys

def main():
  N = int(input())
  P = sys.stdin.readline().rstrip().split()
  if '0' in P:
    print(0)
    return
  ans = 1
  for a in P:
    ans *= int(a)
    if ans > 1000000000000000000:
      print(-1)
      return
  print(ans)

if __name__ == "__main__":
    main()

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

def main():
    n = int(input())
    limit = pow(10,18)
    readStr = input()
    flds = readStr.split(" ")
    res = 1
    for i in range(n):
        if flds[i] == 0:
            res = 0
            break
        res *= int(flds[i])

    if res > limit:
        res = -1
    print(res)

if __name__ == "__main__":
    main()


Fixed submission:
import sys

def main():
  N = int(input())
  P = sys.stdin.readline().rstrip().split()
  if '0' in P:
    print(0)
    return
  ans = 1
  for a in P:
    ans *= int(a)
    if ans > 1000000000000000000:
      print(-1)
      return
  print(ans)

if __name__ == "__main__":
    main()
Buggy python submission (verdict: Time Limit Exceeded):
N, K, Q = map(int, input().split())
A = [int(input()) for _ in range(Q)]
pt = [K - Q]*(N + 1)

for i in range(Q):
  for n in range(len(pt)):
    if n == A[i]:
      pt[n] += 1

for n in range(1, len(pt)):
  if pt[n] > 0:
    print("Yes")
  else:
    print("No")


Fixed submission:
n,k,q = map(int,input().split())
ans = [0]*n
for i in range(q):
    idx = int(input()) -1
    ans[idx] += 1
for i in ans:
    print('Yes' if q-k<i else 'No')

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

def main():
    N, K, Q = map(int, input().split())

    A = [int(input()) for _ in range(Q)]
#   print(A)

    pt = [K]*(N + 1)
#   print(pt)

    for i in range(Q):
        for n in range(len(pt)):
            pt[n] -= 1
            if n == A[i]:
                pt[n] += 1
#       print("{0}: {1}".format(i, pt[1:]))

#   print(pt)
    for n in range(1, len(pt)):
        if pt[n] > 0:
            print("Yes")
        else:
            print("No")

if __name__ == "__main__":
    main()


Fixed submission:
n,k,q = map(int,input().split())
ans = [0]*n
for i in range(q):
    idx = int(input()) -1
    ans[idx] += 1
for i in ans:
    print('Yes' if q-k<i else 'No')
Buggy python submission (verdict: Runtime Error):
    N,K = map(int,input().split())

    print(N - K + 1)


Fixed submission:
N, K = map(int,input().split())
print(N - K + 1)

Buggy python submission (verdict: Runtime Error):
import sys

def main():
    data = input()
    flds = data.split(" ")
    N = int(flds[0])
    K = int(flds[1])

    count = 0
    for i in range(1, N):
        if i + K - 1 <= N:
#           print("%d -  %d" %(i, i + K - 1))
            count += 1

#   print("resut = " %count)
   print(count)

if __name__ == "__main__":
    main()


Fixed submission:
N, K = map(int,input().split())
print(N - K + 1)
Buggy python submission (verdict: Runtime Error):
if (R - L) // 2019 > 0:
    print(0)
elif (R - L) != (R % 2019 - L % 2019):
    print(0)
else:
    print(min(L * (L + 1) % 2019, R * (R - 1) % 2019, L * R % 2019))


Fixed submission:
L, R = map(int, input().split())

if (R - L) // 2019 > 0:
    print(0)
elif (R - L) != (R % 2019 - L % 2019):
    print(0)
else:
    answer = 2019
    for i in range(L, R):
        for j in range(i + 1, R + 1):
            tmp = i * j % 2019
            if tmp < answer:
                answer = tmp
    print(answer)
Buggy python submission (verdict: Runtime Error):
A=int(input())
B=int(input())

print(A*B)

Fixed submission:

tmp=input().split(" ")
A=int(tmp[0])
B=int(tmp[1])

print(A*B)
Buggy python submission (verdict: Time Limit Exceeded):
get_num=int(input())
get_list=[]
count=0

for i in range(get_num):
    tmp=input()
    if (tmp in get_list)==False:
        get_list.append(tmp)
        count+=1;
    
print(count)

Fixed submission:
get_num=int(input())
get_list=[]
count=0

for i in range(get_num):
    tmp=input()
    get_list.append(tmp)

list=list(set(get_list))
    
print(len(list))

Buggy python submission (verdict: Time Limit Exceeded):
get_num=int(input())
get_list=[]

for i in range(get_num):
    tmp=input()
    if (tmp in get_list)==False:
        get_list.append(tmp)
    
print(len(get_list))

Fixed submission:
get_num=int(input())
get_list=[]
count=0

for i in range(get_num):
    tmp=input()
    get_list.append(tmp)

list=list(set(get_list))
    
print(len(list))
Buggy python submission (verdict: Time Limit Exceeded):
N=int(input())
tmp=input().split(" ")

list=[]
for i in range(N-1):
    list.append(int(tmp[i]))

count=0
for i in range(1,N+1):
    for j in range(N-1):
        if i==list[j]:
            count+=1
    print(count)
    count=0

Fixed submission:
N=int(input())
tmp=input().split(" ")

list=[]
for i in range(N-1):
    list.append(int(tmp[i]))

answer=[0]*N

for i in range(N-1):
    answer[list[i]]+=1
answer.append(0)

for i in range(1,N+1):
    print(answer[i])
Buggy python submission (verdict: Runtime Error):
a,b = input()
print(a*b)

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

Buggy python submission (verdict: Runtime Error):
a,b = input()
return a*b

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