Harryxun/testdata huggingface dataset:
Buggy python submission (verdict: Runtime Error):
n = int(input())
r = int(input())
if (n<10):
  print(100*(10-n)+r)
else:
   print(r)

Fixed submission:
n,r = map(int,input().split())
if(n>=10):
  print(r)
else:
  print(100*(10-n)+r)
Buggy python submission (verdict: Runtime Error):
n = int(inpit())
a = list(map(int,input().split()))
m = round(sum(a)/n)
x = 0
for i in a:
  x=+(i-m)**2
print(x)

Fixed submission:
N = int(input())
X = list(map(int, input().split()))
M = round(sum(X)/N)
ans = 0
for i in X:
    ans+=(i-M)**2
print(ans)
Buggy python submission (verdict: Runtime Error):
import math
H = int(input())
A = int(input())
print(math.ceil(H/A))

Fixed submission:
import math

H, A = [int(x) for x in input().split()]
print(math.ceil(H/A))

Buggy python submission (verdict: Runtime Error):
H = int(input())
A = int(input())
c = 0
while (H>0):
    H = H-A
    c = c+1
print(c)

Fixed submission:
import math

H, A = [int(x) for x in input().split()]
print(math.ceil(H/A))

Buggy python submission (verdict: Runtime Error):
b = int(input())
a = int(input())
c = 0
while (b>0):
    b = b-a
    c = c+1
print(c)

Fixed submission:
import math

H, A = [int(x) for x in input().split()]
print(math.ceil(H/A))
Buggy python submission (verdict: Runtime Error):
from itertools import math
N = int(input())
P = tuple(map(int(input().split())))
Q = tuple(map(int(input().split()))
# Find all possible and allow the length
perm = permutations((range(1,N+1)),N)
print(abs(perm.index(P)-perm.index(Q)))


Fixed submission:
from itertools import permutations
N = int(input())
P = tuple(map(int,input().split()))
Q = tuple(map(int,input().split()))
# Find all possible
perm = list(permutations(range(1,N+1),N))
print(abs(perm.index(P)- perm.index(Q)))
Buggy python submission (verdict: Runtime Error):
import java.util.Scanner;
public class Main {
    public static void main(String[] args) {
        Scanner s = new Scanner(System.in);
        String a = s.nextLine();
        String b = s.nextLine();
        String c = b.concat(a);
        System.out.println(c);
    }
}


Fixed submission:
s = input().split()
print(s[1]+s[0])
Buggy python submission (verdict: Runtime Error):
import java.util.*;
public class Main{
  public static void main(String[] args){
    	Scanner s = new Scanner(System.in);
    	String word = s.nextLine();
    	int leng = word.length();
    	String re = word.reverse();
    	int c = 0;
    	for(i=leng-1; i<=0; i--){
          if(word.charAt(i) == re.charAt(i)){
            	continue;
          }else
            c++;
        }
    System.out.println(c/2);
  }
}

Fixed submission:
n = input()
count = 0
first, second = n[:len(n)//2], n[(len(n)+1)//2:]
if first == reversed(second):
    print(count)
else:
    for x in range(len(first)):
        if first[x] != second[len(second)-x-1]:
            count += 1
    print(count)
Buggy python submission (verdict: Runtime Error):
def resolve():
    import sys

    input = lambda: sys.stdin.readline().rstrip()

    a, b, c, k = map(int,input().split())
    
    if a + b >= k:
      print(k)
      sys.exit()

    arr = [1] * a + [0] * b + [-1] * c

    print(sum(arr[0:k]))

resolve()

Fixed submission:
def resolve():
    import sys

    input = lambda: sys.stdin.readline().rstrip()

    a, b, c, k = map(int,input().split())
    
    if a >= k:
      print(k)
    elif a + b >= k:
      print(a)
    else:
      print(a-(k-(a+b)))
      
resolve()

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

    input = lambda: sys.stdin.readline().rstrip()

    a, b, c, k = map(int,input().split())
    
    if a <= k:
      print(k)
      sys.exit()

    arr = [1] * a + [0] * b + [-1] * c

    print(sum(arr[0:k]))

resolve()

Fixed submission:
def resolve():
    import sys

    input = lambda: sys.stdin.readline().rstrip()

    a, b, c, k = map(int,input().split())
    
    if a >= k:
      print(k)
    elif a + b >= k:
      print(a)
    else:
      print(a-(k-(a+b)))
      
resolve()

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

    input = lambda: sys.stdin.readline().rstrip()

    a, b, c, k = map(int,input().split())

    arr = [1] * a + [0] * b + [-1] * c

    print(sum(arr[0:k]))

resolve()

Fixed submission:
def resolve():
    import sys

    input = lambda: sys.stdin.readline().rstrip()

    a, b, c, k = map(int,input().split())
    
    if a >= k:
      print(k)
    elif a + b >= k:
      print(a)
    else:
      print(a-(k-(a+b)))
      
resolve()
Buggy python submission (verdict: Time Limit Exceeded):
frege_count, oven_count, coupon_count = map(int,input().split())	
frege_prices = list(map(int,input().split()))	
oven_prices = list(map(int,input().split()))	
coupon_list = [list(map(int, input().split())) for i in range(coupon_count)]

minprice = 200000
for f in range(frege_count):
  for o in range(oven_count):
      total_cost = frege_prices[f] +  oven_prices[o]
      if minprice > total_cost:
          minprice = total_cost
for coupon in coupon_list:
  total_cost = frege_prices[coupon[0]-1] + oven_prices[coupon[1]-1] - coupon[2]
  if minprice > total_cost:
          minprice = total_cost
print(minprice)

Fixed submission:
frege_count, oven_count, coupon_count = map(int,input().split())	
frege_prices = list(map(int,input().split()))	
oven_prices = list(map(int,input().split()))	
coupon_list = [list(map(int, input().split())) for i in range(coupon_count)]

minprice = min(frege_prices) + min(oven_prices)
for coupon in coupon_list:
  total_cost = frege_prices[coupon[0]-1] + oven_prices[coupon[1]-1] - coupon[2]
  if minprice > total_cost:
          minprice = total_cost
print(minprice)
Buggy python submission (verdict: Runtime Error):
a=input()
s=a%2
if a==1:
    print(a/2+1)
else:
    print(a/2)

Fixed submission:
import math

a=int(input())
s=a/2
print(math.ceil(s))
Buggy python submission (verdict: Runtime Error):
n=input()
a,b,c=map(int,input().split())


Fixed submission:
a,b=map(int,input().split())
c=a-b*2
if 0>c:
    print(0)
else:
    print(c)
Buggy python submission (verdict: Runtime Error):
l,r=map(int,input().split())
s=list()
if l+1==r:
    print(l*r)
else:
    for i in range(l,r):
        s.append([i*(i+1)%2019])
    #print(s[0][0])
    s=(sorted(s))
    print(s[0][0])

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

d=a*n
if d>b:
    print(b)
else:
    print(d)
Buggy python submission (verdict: Runtime Error):
n=int(input())
p=list(map(int,input().split()))

for i in range(1,n-1):

    if (p[i-1]<p[i]<p[i+1]) or (p[i+1]<p[i]<p[i-1]):
        a=1+a
print(a)

Fixed submission:
n=int(input())
p=list(map(int,input().split()))
#print(n)
#print(p)
a=0
i=1

for i in range(1,n-1):

    if (p[i-1]<p[i]<p[i+1]) or (p[i+1]<p[i]<p[i-1]):
        a=1+a
print(a)
    #sumir=vie(i)+sumir
#print("")
#print(sumir)
Buggy python submission (verdict: Runtime Error):
a

Fixed submission:
import re                                                                                                        
import copy                                                                                                      

n,a,b,c,d=map(int,input().split())                                                                               
s=input()                                                                                                        
a-=1                                                                                                             
b-=1                                                                                                             
c-=1                                                                                                             
d-=1                                                                                                             

if "##" in s[a:c+1] or "##" in s[b:d+1]:                                                                                 
    print("No")                                                                                                  
else:                                                                                                            
    if c<d:                                                                                                      
        print("Yes")                                                                                             
    else:                                                                                                        
        if "..." in s[b-1:d+2]:                                                                                  
            print("Yes")                                                                                         
        else:                                                                                                    
            print("No")
Buggy python submission (verdict: Runtime Error):
a,b=map(int,input().split())↲
d=0
c=a*3
if c>=1:
  d=(c+b)//2
elif c==0 and b>1:
  d=b//2
print(d)↲


Fixed submission:
a, p = map(int, input().split())
#print (int((a*3 + p) / 2))
#a,p=map(int,input().split())↲
print(int((a*3+p)/2))

Buggy python submission (verdict: Runtime Error):
a,b=map(int,input().split())↲
d=0
c=a*3
if c>1:
    d=(c+b)//2
elif c==0 and b>1:
    d=b//2
print(d)↲


Fixed submission:
a, p = map(int, input().split())
#print (int((a*3 + p) / 2))
#a,p=map(int,input().split())↲
print(int((a*3+p)/2))

Buggy python submission (verdict: Runtime Error):
a,p=map(int,input().split())↲
print(int((a*3+p)/2))


Fixed submission:
a, p = map(int, input().split())
#print (int((a*3 + p) / 2))
#a,p=map(int,input().split())↲
print(int((a*3+p)/2))

Buggy python submission (verdict: Runtime Error):
a,p=map(int,input().split())↲
c=(a*3+p)//2
print(int(c))

Fixed submission:
a, p = map(int, input().split())
#print (int((a*3 + p) / 2))
#a,p=map(int,input().split())↲
print(int((a*3+p)/2))

Buggy python submission (verdict: Runtime Error):
a,p=map(int,input().split())↲
c=(a*3+p)//2
print(c)

Fixed submission:
a, p = map(int, input().split())
#print (int((a*3 + p) / 2))
#a,p=map(int,input().split())↲
print(int((a*3+p)/2))

Buggy python submission (verdict: Runtime Error):
A,P=map(int,input().split())↲
N=0↲
a=A*3↲
if a>1:
  N=(a+P)//2
elif a==0 and P>1:
  N=P//2
print(N)

Fixed submission:
a, p = map(int, input().split())
#print (int((a*3 + p) / 2))
#a,p=map(int,input().split())↲
print(int((a*3+p)/2))

Buggy python submission (verdict: Runtime Error):
A,P=map(int,input().split())↲
d=0
c=A*3
if c>1:
  d=(c+P)//2
elif c==0 and P>1:
  d=P//2
print(d)↲

Fixed submission:
a, p = map(int, input().split())
#print (int((a*3 + p) / 2))
#a,p=map(int,input().split())↲
print(int((a*3+p)/2))

Buggy python submission (verdict: Runtime Error):
a,b=map(int,input().split())↲
d=0
c=a*3
if c>1:
  d=(c+b)//2
elif c==0 and b>1:
  d=b//2
print(d)↲

Fixed submission:
a, p = map(int, input().split())
#print (int((a*3 + p) / 2))
#a,p=map(int,input().split())↲
print(int((a*3+p)/2))

Buggy python submission (verdict: Runtime Error):
a,b=map(int,input().split())↲
d=0
c=a*3
if c>1:
  d=(c+b)//2
print(d)↲

Fixed submission:
a, p = map(int, input().split())
#print (int((a*3 + p) / 2))
#a,p=map(int,input().split())↲
print(int((a*3+p)/2))

Buggy python submission (verdict: Runtime Error):
a,b=map(int,input().split())↲
d=0
c=a*3
if b>1:
  d=(c+b)//2
print(d)↲

Fixed submission:
a, p = map(int, input().split())
#print (int((a*3 + p) / 2))
#a,p=map(int,input().split())↲
print(int((a*3+p)/2))

Buggy python submission (verdict: Runtime Error):
a,b=map(int,input().split())↲
c=a*3
d=c+d/2
print(d)↲

Fixed submission:
a, p = map(int, input().split())
#print (int((a*3 + p) / 2))
#a,p=map(int,input().split())↲
print(int((a*3+p)/2))

Buggy python submission (verdict: Runtime Error):
a,b=int(input().split())↲
c=a*3
d=c+d/2

print(d)↲

Fixed submission:
a, p = map(int, input().split())
#print (int((a*3 + p) / 2))
#a,p=map(int,input().split())↲
print(int((a*3+p)/2))
Buggy python submission (verdict: Runtime Error):
a,b=map(int, input().split())
if a<=5:
    b=0
elif 6<=a<=12:
    b=b/2
  
 print(int(b))


Fixed submission:
a,b=map(int, input().split())
if a<=5:
    b=0
elif 6<=a<=12:
    b=b/2
print(int(b))

Buggy python submission (verdict: Runtime Error):
a,b=map(int, input().split())
if a<=5:
  b=0
elif 6<=a<=12:
  b=b/2
  
 print(int(b))

Fixed submission:
a,b=map(int, input().split())
if a<=5:
    b=0
elif 6<=a<=12:
    b=b/2
print(int(b))

Buggy python submission (verdict: Runtime Error):
a,b=map(int, input().split())
if a<=5:
  b=0
elif 6<=a<=12:
  b=b/2
  
 print(b)

Fixed submission:
a,b=map(int, input().split())
if a<=5:
    b=0
elif 6<=a<=12:
    b=b/2
print(int(b))
Buggy python submission (verdict: Runtime Error):
import math
a,b,h,m = map(int,input().split())
x = 6 * m - 15 * h
k = math.cos(math.radians(x))
c = a ** 2 + b ** 2 - 2 * a * b * k
print(math.sqrt(c))             


Fixed submission:
i = int(input())
if i % 10 == 3:
  print("bon")
elif i % 10 == 0 or i % 10 ==1 or i % 10 == 6 or i % 10 ==8:
  print("pon")
else:
  print("hon")
Buggy python submission (verdict: Runtime Error):
S = import()
if S == ABC:
  print("ARC")
else:
  print("ABC")

Fixed submission:
S = input()
if S == "ABC":
  print("ARC")
else:
  print("ABC")
Buggy python submission (verdict: Runtime Error):
a = []
a = input()
f = len(a)



print(a[3])


if a[f-1] == "3":
  print("bon")
elif a[f-1] == "0" or a[f-1] == "6" or a[f-1] == "1" or a[f-1] == "8":
  print("pon")
else:
  print("hon")

Fixed submission:
a = []
a = input()
f = len(a)






if a[f-1] == "3":
  print("bon")
elif a[f-1] == "0" or a[f-1] == "6" or a[f-1] == "1" or a[f-1] == "8":
  print("pon")
else:
  print("hon")
Buggy python submission (verdict: Runtime Error):
def get_int(s, si, ei=None):
    #print(f'get_int: s={s}, si={si}, ei={ei}')
    if ei is None:
        value = int(s[si:])
    else:
        value =  int(s[si:ei])
    #print(f'value={value}')
    return value


BIT = 1

str_s = input()
s = int(str_s)
slen = len(str_s)

result = 0
for i in range(2 ** (slen - 1) ):
    #print(f'======= i={bin(i)} ========')
    s_index = 0
    for k in range(slen - 1):
        bit = (i >> k) & BIT        
        if bit == 0:
            continue
        e_index = k + 1
        value = get_int(str_s, s_index, e_index)
        result += value
        s_index = e_index
    value = get_int(str_s, s_index)
    result += value

print(result)


Fixed submission:
import re

s = input()
t = input()

def check(s, t):
    p = re.compile('[a-z]+')
    if not p.match(s) or not p.match(t):
        return 'No'
    if len(s) < 1 or len(s) > 10:
        return 'No'
    if len(s) + 1 != len(t):
        return 'No'
    if t[0:len(s)] != s:
        return 'No'
    return 'Yes'

print(check(s, t))
Buggy python submission (verdict: Time Limit Exceeded):
def remove_from(arr, item):
    if item in arr:
        arr.remove(item)

(n, m) = list(map(int, input().split()))
hights = list(map(int, input().split()))
tmap = {}
for i, h in enumerate(hights):
    tmap[i + 1] = h

nlist = list(range(1, n + 1))
for i in range(m):
    (s, d) = list(map(int, input().split()))
    if tmap[s] < tmap[d]:
        remove_from(nlist, s)
    elif tmap[s] > tmap[d]:
        remove_from(nlist, d)
    else:
        remove_from(nlist, s)
        remove_from(nlist, d)
print(len(nlist))

Fixed submission:
(n, m) = list(map(int, input().split()))
hights = list(map(int, input().split()))

bads = set([])
for _ in range(m):
    (s, d) = list(map(int, input().split()))
    if hights[s-1] < hights[d-1]:
        bads.add(s)
    elif hights[s-1] > hights[d-1]:
        bads.add(d)
    elif hights[s-1] == hights[d-1]:
        bads.add(s)
        bads.add(d)
print(len(hights) - len(bads))
Buggy python submission (verdict: Runtime Error):
tems = list(map(lambda x: int(x), input().split()))
s = items[0]
w = items[1]
print('safe' if s > w else 'unsafe')

Fixed submission:
items = list(map(lambda x: int(x), input().split()))
s = items[0]
w = items[1]
print('safe' if s > w else 'unsafe')
Buggy python submission (verdict: Time Limit Exceeded):
(k, s) = list(map(int, input().split()))
count = 0
for x in range(k + 1):
    if s - x > k * 2:
        continue
    for y in range(k + 1):
        if s - x - y > k:
            continue
        for z in range(k + 1):
            if s == x + y + z:
                count += 1
print(count)

Fixed submission:
(k, s) = list(map(int, input().split()))
count = 0
for x in range(k + 1):
    for y in range(k + 1):
        z = s - x - y
        if z >= 0 and z <= k:
            count += 1
print(count)

Buggy python submission (verdict: Time Limit Exceeded):
(k, s) = list(map(int, input().split()))
count = 0
for x in range(k + 1):
    for y in range(k + 1):
        for z in range(k + 1):
            if s == x + y + z:
                count += 1
print(count)

Fixed submission:
(k, s) = list(map(int, input().split()))
count = 0
for x in range(k + 1):
    for y in range(k + 1):
        z = s - x - y
        if z >= 0 and z <= k:
            count += 1
print(count)
Buggy python submission (verdict: Runtime Error):
S = input()
T = input()

ans = "No"
if len(S)+1 == len(T):
	if T.startswith(S) is True:
      ans = "Yes"
print(ans)

Fixed submission:
S = input()
T = input()
 
ans = "No"
if len(S)+1 == len(T):
  if T.startswith(S) is True:
    ans = "Yes"
print(ans)
Buggy python submission (verdict: Runtime Error):
A,B,C,K = map(int, input().split())
card_list = [1]*A + [0]*B + [-1]*C
 
print(sum(card_list[0:K]))

Fixed submission:
A,B,C,K = map(int, input().split())
ans = 0
if K <= A:
  ans = K
else:
  if K > A and K <= A+B:
    ans = A
  else:
    ans = A-(K-A-B)
print(ans)

Buggy python submission (verdict: Runtime Error):
A,B,C,K = map(int, input().split())
card_list = (([1]*A).extend([0]*B)).extend([-1]*C)
 
print(sum(card_list[0:K]))

Fixed submission:
A,B,C,K = map(int, input().split())
ans = 0
if K <= A:
  ans = K
else:
  if K > A and K <= A+B:
    ans = A
  else:
    ans = A-(K-A-B)
print(ans)

Buggy python submission (verdict: Runtime Error):
A,B,C,K = map(int, input().split())
card_list = (([1]*A).extend([0]*B)).append([-1]*C)

print(sum(card_list[0:K]))

Fixed submission:
A,B,C,K = map(int, input().split())
ans = 0
if K <= A:
  ans = K
else:
  if K > A and K <= A+B:
    ans = A
  else:
    ans = A-(K-A-B)
print(ans)
Buggy python submission (verdict: Runtime Error):
n,k=map(int,input().split())
kashi = [0] * n
cnt = 0
M = 0
for s in range(n-1):
	i=int(input())
	li=list(map(int,input().split()))
	if i > 0:
		for m in li:
			kashi[m-1] +=1

for i in kashi:
	if i == 0:
		cnt += 1

print(cnt)
    

Fixed submission:
n,k=map(int,input().split())
kashi = [0] * n
cnt = 0
M = 0
for s in range(k):
	i=int(input())
	li=list(map(int,input().split()))
	if i > 0:
		for m in li:
			kashi[m-1] +=1

for i in kashi:
	if i == 0:
		cnt += 1

print(cnt)

Buggy python submission (verdict: Runtime Error):
n,k=map(int,input().split())
kashi = [0] * n
cnt = 0
M = 0
for s in range(n):
	i=int(input())
	li=list(map(int,input().split()))
	if i > 0:
		for m in li:
			kashi[m-1] +=1

for i in kashi:
	if i == 0:
		cnt += 1

print(cnt)
    

Fixed submission:
n,k=map(int,input().split())
kashi = [0] * n
cnt = 0
M = 0
for s in range(k):
	i=int(input())
	li=list(map(int,input().split()))
	if i > 0:
		for m in li:
			kashi[m-1] +=1

for i in kashi:
	if i == 0:
		cnt += 1

print(cnt)

Buggy python submission (verdict: Runtime Error):
n,k=map(int,input().split())
kashi = [0] * n
cnt = 0
M = 0
for s in range(n):
	i=int(input())
	li=list(map(int,input().split()))
	for m in li:
		kashi[m-1] +=1

for i in kashi:
	if i == 0:
		cnt += 1

print(cnt)
    

Fixed submission:
n,k=map(int,input().split())
kashi = [0] * n
cnt = 0
M = 0
for s in range(k):
	i=int(input())
	li=list(map(int,input().split()))
	if i > 0:
		for m in li:
			kashi[m-1] +=1

for i in kashi:
	if i == 0:
		cnt += 1

print(cnt)

Buggy python submission (verdict: Runtime Error):
n,k=map(int,input().split())
kashi = [0] * n
cnt = 0
for s in range(n-1):
	i=int(input())
	li=list(map(int,input().split()))
	for m in li:
		kashi[m-1] +=1

for i in kashi:
	if i == 0:
		cnt += 1

print(cnt)

Fixed submission:
n,k=map(int,input().split())
kashi = [0] * n
cnt = 0
M = 0
for s in range(k):
	i=int(input())
	li=list(map(int,input().split()))
	if i > 0:
		for m in li:
			kashi[m-1] +=1

for i in kashi:
	if i == 0:
		cnt += 1

print(cnt)
Buggy python submission (verdict: Runtime Error):
x = int(input())
year = 0
yen = 100
while x > yen:
  yen = int(yen*1.01)
  year+=
  
print(year)

Fixed submission:
x = int(input())
year = 0
yen = 100

while x>yen:
  yen = int(yen*1.01)
  year+=1

print(year)
Buggy python submission (verdict: Runtime Error):
n = innput()
 
if "7" in n:
  print("Yes")
else:
  print("No")

Fixed submission:
n = str(input())
m = "7"
if m in n:
  print("Yes")
else:
  print("No")

Buggy python submission (verdict: Runtime Error):
n = int(innput())

if n in 7:
  print("Yes")
  else:
  print("No")

Fixed submission:
n = str(input())
m = "7"
if m in n:
  print("Yes")
else:
  print("No")
Buggy python submission (verdict: Runtime Error):
n,m=map(int,input())
N=n
x=0
z=m
for i in range(100):
    x=N-z
    x=abs(x)
    z=x*z
    N=min(N,x,n)

print(N) 

Fixed submission:
x,y,z=map(int,input().split())
v=0

v=x
x=y
y=v

v=x
x=z
z=v
print(x,y,z)

Buggy python submission (verdict: Runtime Error):
n,m=map(int,input().split())
a=list(map(int,input().split()))
 
toku = sum(a) // (4*m)
 
a.sort(reverse=True)
if a[m-1] >= toku:
  print("Yes")
  else:
  print("No")

Fixed submission:
x,y,z=map(int,input().split())
v=0

v=x
x=y
y=v

v=x
x=z
z=v
print(x,y,z)

Buggy python submission (verdict: Runtime Error):
x,y,z=int(input())
v=0

v=x
x=y
y=v

v=x
x=z
z=v
print(x,y,z)

Fixed submission:
x,y,z=map(int,input().split())
v=0

v=x
x=y
y=v

v=x
x=z
z=v
print(x,y,z)
Buggy python submission (verdict: Runtime Error):
n,m=map(int,input().split())
a=list(map(int,input().split()))
 
toku = sum(a) // (4*m)
 
a.sort(reverse=True)
if a[m-1] >= toku:
  print("Yes")
  else:
  print("No")

Fixed submission:
n,m=map(int,input().split())
a=list(map(int,input().split()))

toku = sum(a) / (4 * m)
a=sorted(a,reverse=True)
    
if a[m-1] >= toku:
    print("Yes")
else:
    print("No")

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

toku = sum(a) // (4*m)

a.sort(reverse=True)
if a[m-1] >= toku:
  print("Yes")
  else:
  print("No")

Fixed submission:
n,m=map(int,input().split())
a=list(map(int,input().split()))

toku = sum(a) / (4 * m)
a=sorted(a,reverse=True)
    
if a[m-1] >= toku:
    print("Yes")
else:
    print("No")
Buggy python submission (verdict: Runtime Error):
S = list(input())
S =[2:5:1]
coffee = ["f","f","e","e"]
  
if S == coffee:
    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):
S = list(input())
coffee = ["c","o","f","f","e","e"]
if S == coffee:
    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):
X = int(input())
fh = x // 500
f = (x - (500*fh)) // 5
pint(f*5+fh*1000)

Fixed submission:
x = int(input())
fh = x // 500
f = (x - (500*fh)) // 5
sum = f*5+fh*1000
print(sum)

Buggy python submission (verdict: Runtime Error):
X = int(input())
fh = x // 500
f = (x - (500*fh)) // 5
pint(f*1000+fh*5)

Fixed submission:
x = int(input())
fh = x // 500
f = (x - (500*fh)) // 5
sum = f*5+fh*1000
print(sum)

Buggy python submission (verdict: Runtime Error):
X = int(input())
fh = x // 500
f = (x - (500*fh)) // 5
pint(f+fh)

Fixed submission:
x = int(input())
fh = x // 500
f = (x - (500*fh)) // 5
sum = f*5+fh*1000
print(sum)

Buggy python submission (verdict: Runtime Error):
X = int(input())
fh = x // 500
f = x - 2*fh // 5
pint(f+fh)

Fixed submission:
x = int(input())
fh = x // 500
f = (x - (500*fh)) // 5
sum = f*5+fh*1000
print(sum)