ZhenlongDai/ACPR huggingface dataset:
Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
N,K = map(int,input().split())
P = list(map(int,input().split()))
P.sort()
res = 0
i = 0
while(K):
	res += P[i]
	K -= 1
print(res)


Failing test case input:
5 3
50 100 80 120 80

Expected output:
210

Actual output:
150


Fixed submission (verdict: Accepted):
N,K = map(int,input().split())
P = list(map(int,input().split()))
P.sort()
res = 0
i = 0
while(K):
    res += P[i]
    K -= 1
    i += 1
print(res)

Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
import heapq
N,K = map(int,input().split())
p = list(map(int,input().split()))
sum(heapq.nsmallest(K,p))

Failing test case input:
-1 4
-1 000 10 17 238

Expected output:
26


Actual output:

Fixed submission (verdict: Accepted):
import heapq
N,K = map(int,input().split())
p = list(map(int,input().split()))
print(sum(heapq.nsmallest(K,p)))

Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
n, k = map(int, input().split())
plist = list(map(int, input().split()))

plist.sort()
ans = sum(plist, k)

print(ans)

Failing test case input:
5 2
95 101 80 21 10

Expected output:
31


Actual output:
309


Fixed submission (verdict: Accepted):
n, k = map(int, input().split())
plist = list(map(int, input().split()))

plist.sort()
ans = 0
for i in range(k):
    ans += plist[i]

print(ans)

Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
N,K=(int(x) for x in input().split())
p=list(map(int, input().split()))
ld = sorted(p, reverse=True)
l=(ld[:K])
print(sum(l))

Failing test case input:
1 3
60 001 6 328 1

Expected output:
8


Actual output:
394


Fixed submission (verdict: Accepted):
N,K=(int(x) for x in input().split())
p=list(map(int, input().split()))
ld = sorted(p)
l=(ld[:K])
print(sum(l))

Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
N,K = map(int, input().split())
p_list= list(map(int, input().split()))

print(sum(sorted(p_list)[:N]))

Failing test case input:
3 2
27 001 16 173 10

Expected output:
11


Actual output:
27


Fixed submission (verdict: Accepted):
n,k = map(int, input().split())
p = list(map(int, input().split()))

print(sum(sorted(p)[:k]))

Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
N, K = map(int,input().split())
p = list(map(int,input().split()))
p.sort()
ls = []
for i in range(K):
    ls.append(p[i])


Failing test case input:
-1 1
17 101 3 -2 3

Expected output:
-2


Actual output:

Fixed submission (verdict: Accepted):
N, K = map(int,input().split())
p = list(map(int,input().split()))
p.sort()
ls = []
for i in range(K):
    ls.append(p[i])
print(sum(ls))
Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
from sys import stdin

N, K = map(int, input().split())
prices = list(map(int, input().split()))

prices = sorted(prices)

sum = 0
for i in range(0, K):
    print(prices[i])
    sum += prices[i]
print(sum)

Failing test case input:
5 3
68 001 80 116 54

Expected output:
123


Actual output:
1
54
68
123


Fixed submission (verdict: Accepted):
from sys import stdin

N, K = map(int, input().split())
prices = list(map(int, input().split()))

prices = sorted(prices)

sum = 0
for i in range(0, K):
    sum += prices[i]
print(sum)

Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
n, k = map(int, input().split())
li = list(input().split())

li.sort(key = int)

print(li)

j = 0
i = 0

while i <= k-1:
  
  j += int(li[i])
  i += 1

print(j)

Failing test case input:
2 4
83 001 9 120 174

Expected output:
213


Actual output:
['001', '9', '83', '120', '174']
213


Fixed submission (verdict: Accepted):
n, k = map(int, input().split())
li = list(input().split())

li.sort(key = int)

j = 0
i = 0

while i <= k-1:
  
  j += int(li[i])
  i += 1

print(j)

Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
A=list(input().split(" "))
B=list(input().split(" "))
C=sorted(B)
D=[]
M=0
for i in range(int(A[1])):
    D.append(int(C[i]))
for j in range(len(D)):
    M=D[j]+M
print(M)

Failing test case input:
3 3
83 001 130 120 145

Expected output:
204


Actual output:
251


Fixed submission (verdict: Accepted):
A=list(input().split(" "))
B=list(input().split(" "))
for i in range(len(B)):
    B[i]=int(float(B[i]))
C=sorted(B)
D=[]
M=0
for i in range(int(A[1])):
    D.append(int(C[i]))
for j in range(len(D)):
    M=D[j]+M
print(M)

Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
n, k = map(int, input().split())
p = list(map(int, input().split()))

print(sum(sorted(p)[:3]))

Failing test case input:
1 4
109 000 4 -1 126

Expected output:
112


Actual output:
3


Fixed submission (verdict: Accepted):
n, k = map(int, input().split())
p = list(map(int, input().split()))

print(sum(sorted(p)[:k]))

Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
if __name__ == "__main__":
    N, K = list(map(int, input().split()))
    p = list(map(int, input().split()))

    print(p)
    p.sort()
    print(p)

    sum = 0
    for i in range(K):
        sum += p[i]
    
    print(sum)

Failing test case input:
8 3
28 010 20 173 80

Expected output:
58


Actual output:
[28, 10, 20, 173, 80]
[10, 20, 28, 80, 173]
58


Fixed submission (verdict: Accepted):
if __name__ == "__main__":
    N, K = list(map(int, input().split()))
    p = list(map(int, input().split()))
    p.sort()
    sum = 0
    for i in range(K):
        sum += p[i]
    
    print(sum)
Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
N, K = map(int, input().split())

P = list(map(int, input().split()))

print(sum(P[:K]))

Failing test case input:
3 1
27 001 11 434 5

Expected output:
1


Actual output:
27


Fixed submission (verdict: Accepted):
N, K = map(int, input().split())
 
P = list(map(int, input().split()))
P.sort()
 
print(sum(P[:K]))

Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
a = list(map(int, input().split()))
p = list(map(int, input().split()))

N = a[0]
K = a[1]

p.sort()

g = sum(p[0:K-1])
print(g)

Failing test case input:
8 3
28 010 20 173 27

Expected output:
57


Actual output:
30


Fixed submission (verdict: Accepted):
a = list(map(int, input().split()))
p = list(map(int, input().split()))

N = a[0]
K = a[1]

p.sort()

g = 0
for k in range(K):
	g = g + p[k]
print(g)

Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
n, k = map(int, input().split())
p = list(map(int, input().split()))
p.sort()

sum = 0
cnt = 0
for i in p:
    sum += i
    cnt += 1
    if cnt == 3:
        break
print(sum)


Failing test case input:
0 4
83 000 10 17 174

Expected output:
110


Actual output:
27


Fixed submission (verdict: Accepted):
n, k = map(int, input().split())
p = list(map(int, input().split()))
p.sort()

sum = 0
cnt = 0
for i in range(k):
    sum += p[i]
print(sum)

Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):

n,k = map(int,input().split())
p = list(map(int,input().split()))
print(p)

p.sort()

s = 0

for i in range(k):
    s += p[i]

print(s)

Failing test case input:
2 4
83 000 13 120 174

Expected output:
216


Actual output:
[83, 0, 13, 120, 174]
216


Fixed submission (verdict: Accepted):

n,k = map(int,input().split())
p = list(map(int,input().split()))

p.sort()

s = 0

for i in range(k):
    s += p[i]

print(s)

Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
N,K=map(int,input().split())
p=list(map(int,input().split()))
ppp=sorted(p)
print(ppp)
buy=[]
for i in range(K):
    buy.append(ppp[i])
print(sum(buy))

Failing test case input:
3 3
83 001 113 -1 126

Expected output:
83


Actual output:
[-1, 1, 83, 113, 126]
83


Fixed submission (verdict: Accepted):
N,K=map(int,input().split())
p=list(map(int,input().split()))
ppp=sorted(p)
buy=[]
for i in range(K):
    buy.append(ppp[i])
print(sum(buy))

Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
N, K = map(int, input().split())
p = list(map(int, input().split()))

p.sort
total=0

for i in range(K):
    total += p[i]
    
print(total)

Failing test case input:
3 1
27 001 11 434 5

Expected output:
1


Actual output:
27


Fixed submission (verdict: Accepted):
N, K = map(int, input().split())
p = list(map(int, input().split()))

p.sort()
total=0

for i in range(K):
    total += p[i]
    
print(total)
Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
import heapq

n,k = map(int,input().split())
l1 = list(map(int,input().split()))
l2 = heapq.nsmallest(3, l1)
print(sum(l2))

Failing test case input:
2 4
83 000 9 120 174

Expected output:
212


Actual output:
92


Fixed submission (verdict: Accepted):
import heapq

n,k = map(int,input().split())
l1 = list(map(int,input().split()))
l2 = heapq.nsmallest(k, l1)
print(int(sum(l2)))

Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
N,K=map(int,input().split())
ans=0
p=list(map(int,input().split()))

p.sort()

for i in range(K):
    ans+=p[i]

    print(ans)


Failing test case input:
2 4
49 100 4 -2 126

Expected output:
151


Actual output:
-2
2
51
151


Fixed submission (verdict: Accepted):
N,K=map(int,input().split())
ans=0
p=list(map(int,input().split()))

p.sort()

for i in range(K):
    ans+=p[i]

print(ans)

Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
k=int(input()[-1])
print(sum(sorted(list(map(int,input().split()))[:k])))

Failing test case input:
5 3
83 000 80 56 145

Expected output:
136


Actual output:
163


Fixed submission (verdict: Accepted):
n,k=map(int,input().split())
print(sum(sorted(list(map(int,input().split())))[:k]))

Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
S = list(map(int, input().strip().split()))
N = S[0]
K = S[1]
p = list(map(int, input().strip().split()))
lists = []
for l in range(K):
  lists.append(min(p))
  lists.remove(min(p))
  
print(sum(lists))


Failing test case input:
1 5
174 111 22 3 19

Expected output:
329


Actual output:
0


Fixed submission (verdict: Accepted):
S = list(map(int, input().strip().split()))
N = S[0]
K = S[1]
p = list(map(int, input().strip().split()))
lists = []
for l in range(K):
  lists.append(min(p))
  p.remove(min(p))
  
print(sum(lists))

Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
N,K = map(int, input().split())
P = list(map(int,input().split()))

Ans = sorted(P)[0:3:]
print(sum(Ans))

Failing test case input:
3 4
27 001 16 173 99

Expected output:
143


Actual output:
44


Fixed submission (verdict: Accepted):
N,K = map(int, input().split())
P = list(map(int,input().split()))

Ans = sorted(P)[0:K:]
print(sum(Ans))

Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
n,k = map(int,input().split())
a = list(map(int,input().split()))
list.sort(a)
sum(a[0:k])

Failing test case input:
3 4
158 000 113 -1 126

Expected output:
238


Actual output:

Fixed submission (verdict: Accepted):
n,k = map(int,input().split())
a = list(map(int,input().split()))
list.sort(a)
print(sum(a[0:k]))
Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
def main():
    N, K = map(int, input().split())
    p = list(map(int, input().split()))

    p.sort()

    print(sum(p[:3]))


if __name__ == "__main__":
    main()


Failing test case input:
-1 4
-1 000 10 17 238

Expected output:
26


Actual output:
9


Fixed submission (verdict: Accepted):
def main():
    N, K = map(int, input().split())
    p = list(map(int, input().split()))

    p.sort()

    print(sum(p[:K]))


if __name__ == "__main__":
    main()

Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
sum = 0
n, k = list(map(int, input().split()))
p = list(map(int, input().split()))
for i in range(k):
  sum += p[i]
print(sum)

Failing test case input:
5 3
50 100 79 16 150

Expected output:
145


Actual output:
229


Fixed submission (verdict: Accepted):
sum = 0
n, k = list(map(int, input().split()))
p = list(map(int, input().split()))
p.sort()
for i in range(k):
  sum += p[i]
print(sum)

Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
N, K = map(int, input().split())
p = list(map(int, input().split()))
p = sorted(p, reverse=True)

ans = 0
for k in range(K):
  ans += p[k]

print(ans)

Failing test case input:
-1 4
3 000 10 17 319

Expected output:
30


Actual output:
349


Fixed submission (verdict: Accepted):
N, K = map(int, input().split())
p = list(map(int, input().split()))
p = sorted(p)

ans = 0
for i in range(K):
  ans += p[i]

print(ans)

Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
N, K = map(int,input().split())
P = list(map(int,input().split()))
P_sorted = sorted(P)
print(P_sorted)
ans = 0
for i in range(K):
    ans += P_sorted[i]
print(ans)

Failing test case input:
5 3
83 000 76 120 145

Expected output:
159


Actual output:
[0, 76, 83, 120, 145]
159


Fixed submission (verdict: Accepted):
N, K = map(int,input().split())
P = list(map(int,input().split()))
P_sorted = sorted(P)
ans = 0
for i in range(K):
    ans += P_sorted[i]
print(ans)

Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
n,k=map(int, input().split())

P=list(map(int, input().split()))

print(sum(sorted(P)[:3]))

Failing test case input:
2 4
83 000 13 120 37

Expected output:
133


Actual output:
50


Fixed submission (verdict: Accepted):
n,k=map(int, input().split())

P=list(map(int, input().split()))

print(sum(sorted(P)[:k]))

Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
N, C = map(int, input().split())
fruit = input().split()

fruit = [int(x) for x in fruit]

fruit.sort()

print(sum(fruit[:3]))

Failing test case input:
1 4
37 000 4 -2 126

Expected output:
39


Actual output:
2


Fixed submission (verdict: Accepted):
N, K = map(int, input().split())
fruit = input().split()

fruit = [int(x) for x in fruit]

fruit.sort()

print(sum(fruit[:K]))
Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
N, K = map(int, input().split())
A = sorted(map(int, input().split()))
print(A[:K])

Failing test case input:
5 3
83 010 80 120 80

Expected output:
170


Actual output:
[10, 80, 80]


Fixed submission (verdict: Accepted):
N, K = map(int, input().split())
A = sorted(map(int, input().split()))
print(sum(A[:K]))

Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
n,k = map(int, input().split())
l = list(map(int, input().split()))
l1 = sorted(l, reverse= False)
sum = sum(l1[0:3])
print(sum)

Failing test case input:
1 4
158 000 4 -1 126

Expected output:
129


Actual output:
3


Fixed submission (verdict: Accepted):
n,k = map(int, input().split())
l = list(map(int, input().split()))
l1 = sorted(l, reverse= False)
sum = sum(l1[0:k])
print(sum)

Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
n, k = [int(j) for j in input().split(' ')]
p = input().split(' ')
 
p.sort()
sum = 0
 
for i in range(0,k):
  sum+=int(p[i])
  
print(sum)

Failing test case input:
5 3
83 000 80 56 145

Expected output:
136


Actual output:
201


Fixed submission (verdict: Accepted):
n, k = [int(j) for j in input().split(' ')]
p = [int(j) for j in input().split(' ')]
 
p.sort()
sum = 0
 
for i in range(0,k):
  sum+=p[i]
  
print(sum)

Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
if __name__ == "__main__":
    N,k = [int(item) for item in input().split()]
    price_arr = [int(p) for p in input().split()]
    print(sum(sorted(price_arr,reverse=True)[:k]))

Failing test case input:
5 3
83 000 16 120 99

Expected output:
99


Actual output:
302


Fixed submission (verdict: Accepted):
if __name__ == "__main__":
    N,k = [int(item) for item in input().split()]
    price_arr = [int(p) for p in input().split()]
    print(sum(sorted(price_arr)[:k]))

Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
n, k = map(int, input().split())
p = list(map(int, input().split()))
p.sort()
print(p[:k])

Failing test case input:
2 4
83 000 13 120 174

Expected output:
216


Actual output:
[0, 13, 83, 120]


Fixed submission (verdict: Accepted):
n, k = map(int, input().split())
p = list(map(int, input().split()))
p.sort()
print(sum(p[:k]))

Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
n,k = input().split()
a = list()
a = input().split(" ")
a.sort()

k = int(k)
i = 0
sum = 0
while i<k:
    sum+=int(a[i])
    i+=1
    
print(sum)

Failing test case input:
5 3
77 011 56 120 80

Expected output:
144


Actual output:
187


Fixed submission (verdict: Accepted):
n,k = input().split()
k = int(k)-1
a = list()
a = input().split(" ")
b = list()
for i in a:
    b.append(int(i))
b.sort()
sum = 0
while k>=0:
    sum += b[k]
    k -= 1
print(sum)
Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
n,k=map(int,input().split())

p=list(map(int,input().split()))

total=0

for i in range(k):
  total += p[i]
print(total)

Failing test case input:
-1 4
-1 000 14 17 10

Expected output:
23


Actual output:
30


Fixed submission (verdict: Accepted):
n,k=map(int,input().split())

p=list(map(int,input().split()))
p.sort()
total=0

for i in range(k):
  total += p[i]
print(total)

Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
n,k = map(int,input().split())
p = list(map(int,input().split()))
p.sort()
print(sum(p[0:n]))

Failing test case input:
2 4
83 000 9 17 174

Expected output:
109


Actual output:
9


Fixed submission (verdict: Accepted):
n,k = map(int,input().split())
p = list(map(int,input().split()))
p.sort()
print(sum(p[0:k]))

Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
A1, A2 = map(int, input().split())
B = list(map(int,input().split()))	

B.sort()
num = 0

for i in range(A2):
  num = B[i]

print(num)



Failing test case input:
1 5
174 111 22 3 19

Expected output:
329


Actual output:
174


Fixed submission (verdict: Accepted):
A1, A2 = map(int, input().split())
B = list(map(int,input().split()))	

B.sort()
num = 0

for i in range(A2):
  num = num + B[i]
  
print(num)

Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
a, b = [int(x) for x in input().split()]
cs = [int(x) for x in input().split()]
print(a, b)
print(cs)
cs.sort()

print(sum(cs[:b]))

Failing test case input:
1 1
1010

Expected output:
1010


Actual output:
1 1
[1010]
1010


Fixed submission (verdict: Accepted):
a, b = [int(x) for x in input().split()]
cs = [int(x) for x in input().split()]
cs.sort()

print(sum(cs[:b]))

Problem: p02628
Buggy submission (PyPy3 (7.3.0), verdict: Wrong Answer):
N,K = list(map(int, input().split()))
A = list(map(int, input().split()))

S = sorted(A)
ans = 0
for i in range(K):
    ans += S[i]

Failing test case input:
5 3
60 010 56 120 80

Expected output:
126


Actual output:

Fixed submission (verdict: Accepted):
N,K = list(map(int, input().split()))
A = list(map(int, input().split()))

S = sorted(A)
ans = 0
for i in range(K):
    ans += S[i]

print(ans)

Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
n,k = map(int,input().split())
p = list(map(int,input().split()))
p.sort()
print(sum(p[0:n+1]))

Failing test case input:
2 4
49 101 4 -2 126

Expected output:
152


Actual output:
51


Fixed submission (verdict: Accepted):
n,k = map(int,input().split())
p = list(map(int,input().split()))
p.sort()
print(sum(p[0:k]))

Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
N,K=map(int,input().split())
p=list(map(int,input().split()))
B=0
p.sort()
N=N-5
K=K-1
for i in range(0,K):
    B=B+p[i]
    i=i+1
    
print(B)


Failing test case input:
5 3
50 100 80 120 80

Expected output:
210

Actual output:
130


Fixed submission (verdict: Accepted):
N,K=map(int,input().split())
p=list(map(int,input().split()))
B=0
C=0
p.sort()
N=N-5
for i in range(0,K):
    B=B+p[i]
    i=i+1
    
print(B)
Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
N,K = list(map(int,input().split()))
p = list(map(int,input().split()))

p.sort()
print(sum(p[:3]))

Failing test case input:
2 4
83 001 9 120 174

Expected output:
213


Actual output:
93


Fixed submission (verdict: Accepted):
N,K = list(map(int,input().split()))
p = list(map(int,input().split()))

p.sort()
print(sum(p[:K]))

Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
N,K = map(int, input().split())
p = list(map(int, input().split()))

print(sum(sorted(p)[:N]))

Failing test case input:
5 4
82 011 56 120 80

Expected output:
229


Actual output:
349


Fixed submission (verdict: Accepted):
n,k = map(int, input().split())
p = list(map(int, input().split()))

print(sum(sorted(p)[:k]))

Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
x = input()
arr = [int(j) for j in x.split()]
y = input()
main = [int(i) for i in y.split()]
main = sorted(main)
sum = 0
r = 0
while r < arr[1]:
  sum+=main[r]
  r+=1
print(main)


Failing test case input:
0 4
83 000 10 17 174

Expected output:
110


Actual output:
[0, 10, 17, 83, 174]


Fixed submission (verdict: Accepted):
x = input()
arr = [int(j) for j in x.split()]
y = input()
main = [int(i) for i in y.split()]
main = sorted(main)
sum = 0
r = 0
while r < arr[1]:
  sum+=main[r]
  r+=1
print(sum)

Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
N,K=map(int,input().split())
a=map(int,input().split())
ans = sorted(a)
answer = ans[:3]
aaa = sum(answer)
print(aaa)

Failing test case input:
2 4
83 001 9 120 174

Expected output:
213


Actual output:
93


Fixed submission (verdict: Accepted):
N,K=map(int,input().split())
a=map(int,input().split())
ans = sorted(a)
answer = ans[:K]
aaa = sum(answer)
print(aaa)

Problem: p02628
Buggy submission (PyPy3 (7.3.0), verdict: Wrong Answer):
n=list(map(int,input().split()))
p=list(map(int,input().split()))
p.sort()
sum(p[:n[1]])

Failing test case input:
-1 1
1110

Expected output:
1110


Actual output:

Fixed submission (verdict: Accepted):
n=list(map(int,input().split()))
p=list(map(int,input().split()))
p.sort()
print(sum(p[:n[1]]))

Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
N,K = map(int, input().split())
pi= list(map(int, input().split()))

print(sum(sorted(pi)[:N]))

Failing test case input:
1 3
60 011 6 328 1

Expected output:
18


Actual output:
1


Fixed submission (verdict: Accepted):
n,k = map(int, input().split())
p = list(map(int, input().split()))

print(sum(sorted(p)[:k]))

Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
a = input().split()


b = input().split()
b.sort()
sum = 0

for i in range(int(a[1])):
    sum += int(b[i])

print(sum)

Failing test case input:
3 4
27 001 16 173 10

Expected output:
54


Actual output:
200


Fixed submission (verdict: Accepted):
a = input().split()


b = list(map(int, input().split()))
b.sort()

sum = 0

for i in range(int(a[1])):
    sum += b[i]

print(sum)
Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
a,b = map(int,input().split())
l = map(int,input().split())
l = sorted(l)
print(l)
print(sum(l[:b]))

Failing test case input:
5 3
54 100 80 16 17

Expected output:
87


Actual output:
[16, 17, 54, 80, 100]
87


Fixed submission (verdict: Accepted):
a,b = map(int,input().split())
l = list(map(int,input().split()))
l = sorted(l)
print(sum(l[:b]))

Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
N,K = map(int,input().split())
P = list(map(int,input().split()))
sum,cnt = 0,0
for i in range(N):
  sum += sorted(P)[i]
  cnt += 1
  if cnt == 3:
  	break
print(sum)

Failing test case input:
1 3
60 001 12 328 0

Expected output:
13


Actual output:
0


Fixed submission (verdict: Accepted):
N,K = map(int,input().split())
P = list(map(int,input().split()))
sum,cnt = 0,0
for i in range(K):
  sum += sorted(P)[i]
print(sum)

Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
N, K = map(int, input().split())
p = list(map(int,input().split()))

print(sum(list(set(p))))

Failing test case input:
1 3
60 001 6 328 1

Expected output:
8


Actual output:
395


Fixed submission (verdict: Accepted):
N, K = map(int, input().split())
p = list(map(int,input().split()))
p = sorted(p)

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

Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
a,b = map(int,input().split())
l = map(int,input().split())
l = sorted(l)
print(l)
if(a<=b):
    print(sum(l))
else:
    print(sum(l[:b]))

Failing test case input:
5 3
68 001 80 116 80

Expected output:
149


Actual output:
[1, 68, 80, 80, 116]
149


Fixed submission (verdict: Accepted):
a,b = map(int,input().split())
l = list(map(int,input().split()))
l = sorted(l)
print(sum(l[:b]))

Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
n, k = map(int, input().split())
p = list(map(int, input().split()))
p.sort()
print(p[:k])

Failing test case input:
2 4
49 101 4 -2 126

Expected output:
152


Actual output:
[-2, 4, 49, 101]


Fixed submission (verdict: Accepted):
n, k = map(int, input().split())
p = list(map(int, input().split()))
p.sort()
print(sum(p[:k]))

Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
N,K=map(int,input().split())
p=list(map(int,input().split()))
print (p.sort(),sum(p[0:K]))

Failing test case input:
5 3
68 000 80 120 80

Expected output:
148


Actual output:
None 148


Fixed submission (verdict: Accepted):
N,K=map(int,input().split())
p=list(map(int,input().split()))
pa=sorted(p)
print (sum(pa[0:K]))

Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
n,k=map(int,input().split())
P=list(map(int,input().split()))
P.sort()
print(sum(P[0:k+1]))

Failing test case input:
3 3
83 001 89 120 145

Expected output:
173


Actual output:
293


Fixed submission (verdict: Accepted):
n,k=map(int,input().split())
P=list(map(int,input().split()))
P.sort()
print(sum(P[:k]))
Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
n,k=map(int,input().split())
P=list(map(int,input().split()))

P.sort()
print(sum(P[0:3]))

Failing test case input:
-1 4
-1 000 14 17 10

Expected output:
23


Actual output:
9


Fixed submission (verdict: Accepted):
n,k=map(int,input().split())
P=list(map(int,input().split()))
P.sort()
print(sum(P[:k]))

Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
a = list(map(int,input().split()))
b = list(map(int,input().split()))
b.sort()
print(b)
d = b[0:a[1]]
print(sum(d))



Failing test case input:
1 3
60 001 6 328 1

Expected output:
8


Actual output:
[1, 1, 6, 60, 328]
8


Fixed submission (verdict: Accepted):
a = list(map(int,input().split()))
b = list(map(int,input().split()))
b.sort()
d = b[0:a[1]]
print(sum(d))

Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
n,k=map(int,input().split())
p=list(map(int,input().split()))
p.sort()
print(sum(p[:3]))

Failing test case input:
5 5
83 000 80 120 80

Expected output:
363


Actual output:
160


Fixed submission (verdict: Accepted):
n,k=map(int,input().split())
p=list(map(int,input().split()))
p.sort()
print(sum(p[:k]))

Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
n,k = map(int,input().split())
p = list(map(int,input().split()))
p.sort()
print(sum(p[0:k+1]))

Failing test case input:
5 3
54 100 80 16 14

Expected output:
84


Actual output:
164


Fixed submission (verdict: Accepted):
n,k = map(int,input().split())
p = list(map(int,input().split()))
p.sort()
print(sum(p[0:k]))

Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
n, k =map(int, input().split())  
list_p=list(map(int, input().split()))  

list_p.sort()

sum(list_p[:k])

Failing test case input:
3 4
27 001 16 173 10

Expected output:
54


Actual output:

Fixed submission (verdict: Accepted):
n, k =map(int, input().split())  
list_p=list(map(int, input().split()))  

list_p.sort()

print(sum(list_p[:k]))

Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):

if __name__ == "__main__":
  N, K = [int(a) for a in input().split()]
  P = list(map(int, input().split()))
  list.sort(P)
  print(P)
  ans = sum(P[:K])
  print(ans)


Failing test case input:
3 3
83 011 89 120 145

Expected output:
183


Actual output:
[11, 83, 89, 120, 145]
183


Fixed submission (verdict: Accepted):

if __name__ == "__main__":
  N, K = [int(a) for a in input().split()]
  P = list(map(int, input().split()))
  list.sort(P)
  ans = sum(P[:K])
  print(ans)
Problem: p02628
Buggy submission (PyPy3 (7.3.0), verdict: Wrong Answer):
N,K = map(int,input().split())
p = [int(m) for m in input().split()]
p.sort()
ans = 0

if K == 0:
    print(0)
elif K == 1:
    print(*p)
elif K == 2:
    print(p[0]+p[1])
else:
    for i in range(K):
        ans += p[i]
    print(ans)


Failing test case input:
-1 1
0 100 11 434 -1

Expected output:
-1


Actual output:
-1 0 11 100 434


Fixed submission (verdict: Accepted):
N,K = map(int,input().split())
p = [int(i) for i in input().split()]
p.sort()
ans = 0

if K == 1:
    print(p[0])
elif K == 2:
    print(p[0]+p[1])
else:
    for i in range(K):
        ans += p[i]
    print(ans)

Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
n,k = map(int,input().split())
p = list(input().split())
p = [int(x) for x in p]
p.sort()
print(p)
ans =sum(p[0:k])
print(ans)

Failing test case input:
8 3
28 011 20 227 4

Expected output:
35


Actual output:
[4, 11, 20, 28, 227]
35


Fixed submission (verdict: Accepted):
n,k = map(int,input().split())
p = list(input().split())
p = [int(x) for x in p]
p.sort()
ans =sum(p[0:k])
print(ans)

Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
n, k = map(int, input().split())
ps = list(map(int, input().split()))

ps.sort()
ps[0:3]
print(sum(ps[0:3]))

Failing test case input:
-1 1
0 100 11 434 -1

Expected output:
-1


Actual output:
10


Fixed submission (verdict: Accepted):
n, k = map(int, input().split())
ps = list(map(int, input().split()))

ps.sort()
print(sum(ps[0:k]))

Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
n,m=map(int,input().split())
l=list(map(int,input().split()))
s=0
l.sort()
x=l[:m]
print(x)   
print(sum(x))


Failing test case input:
3 3
54 001 16 173 99

Expected output:
71


Actual output:
[1, 16, 54]
71


Fixed submission (verdict: Accepted):
n,m=map(int,input().split())
l=list(map(int,input().split()))
s=0
l.sort()
x=l[:m]
print(sum(x))

Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):




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

    ans = 0
    Ps.sort()
    for p in Ps[0:3]:
        ans += p
    print(ans)


if __name__ == '__main__':
    main()


Failing test case input:
-1 1
17 101 3 -4 2

Expected output:
-4


Actual output:
1


Fixed submission (verdict: Accepted):




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

    ans = 0
    Ps.sort()
    for p in Ps[0:K]:
        ans += p
    print(ans)


if __name__ == '__main__':
    main()

Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
N,K=(int(x) for x in input().split())
p = list(map(int, input().split()))

p = p.sort

K = 0
for i in range(K):
    K = K+p(i)

print(K)

Failing test case input:
9 3
28 000 9 173 80

Expected output:
37


Actual output:
0


Fixed submission (verdict: Accepted):
a = list(map(int, input().split()))
p = list(map(int, input().split()))

N = a[0]
K = a[1]

p.sort()

g = 0
for k in range(K):
	g = g + p[k]
print(g)
Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
import sys
read = sys.stdin.buffer.read
readline = sys.stdin.buffer.readline
readlines = sys.stdin.buffer.readlines

n, k, *p = map(int, read().split())
p.sort()
print(sum(p[:3]))

Failing test case input:
2 4
83 000 13 120 37

Expected output:
133


Actual output:
50


Fixed submission (verdict: Accepted):
import sys
read = sys.stdin.buffer.read
readline = sys.stdin.buffer.readline
readlines = sys.stdin.buffer.readlines

n, k, *p = map(int, read().split())
p.sort()
print(sum(p[:k]))

Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
prices = []
total_fruits = 0
max_numb = 0

total_fruits, max_numb = input().split(' ')
tmp_prices = input().split(' ')
tmp_prices.sort()
ans = 0
for i in range(int(max_numb)):
  ans += int(tmp_prices[i])
  
print(ans)
  

Failing test case input:
3 3
27 000 11 239 5

Expected output:
16


Actual output:
250


Fixed submission (verdict: Accepted):
prices = []
total_fruits = 0
max_numb = 0

total_fruits, max_numb = input().split(' ')
tmp_prices = input().split(' ')
tmp_prices = [int(i) for i in tmp_prices]
tmp_prices.sort()
ans = 0
for i in range(int(max_numb)):
  ans += int(tmp_prices[i])
  
print(ans)

Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
n,k = map(int, input().split())
p = list(map(int, input().split()))

print(sum(sorted(p)[:n+1]))


Failing test case input:
1 4
109 000 4 -1 126

Expected output:
112


Actual output:
-1


Fixed submission (verdict: Accepted):
n,k = map(int, input().split())
p = list(map(int, input().split()))

print(sum(sorted(p)[:k]))

Problem: p02628
Buggy submission (PyPy3 (7.3.0), verdict: Wrong Answer):
N,K = map(int,input().split())
p = [int(m) for m in input().split()]
p.sort()
ans = 0

if K == 1:
    print(*p)
elif K == 2:
    print(p[0]+p[1])
else:
    for i in range(K):
        ans += p[i]
    print(ans)

Failing test case input:
-1 1
17 101 3 -4 2

Expected output:
-4


Actual output:
-4 2 3 17 101


Fixed submission (verdict: Accepted):
N,K = map(int,input().split())
p = [int(i) for i in input().split()]
p.sort()
ans = 0

if K == 1:
    print(p[0])
elif K == 2:
    print(p[0]+p[1])
else:
    for i in range(K):
        ans += p[i]
    print(ans)

Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
a,b = map(int, input().split())
arr = list(map(int, input().split()))
print(sum(arr[:b]))

Failing test case input:
3 3
83 001 89 1 126

Expected output:
85


Actual output:
173


Fixed submission (verdict: Accepted):
a,b = map(int, input().split())
arr = list(map(int, input().split()))
arr.sort()
print(sum(arr[:b]))

Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
n, k = map(int,input().split())
l = sorted(list(map(int,input().split())))
 


print(sum(l[:3]))

Failing test case input:
2 4
83 000 13 120 37

Expected output:
133


Actual output:
50


Fixed submission (verdict: Accepted):
n, k = map(int,input().split())
l = sorted(list(map(int,input().split())))
 


print(sum(l[:k]))
Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
N, K = map(int, input().split())
p = list(map(int, input().split()))

p = sorted(p, reverse=True)
ans = 0
for k in range(K):
  ans += p[k]

Failing test case input:
5 3
28 000 20 120 80

Expected output:
48


Actual output:

Fixed submission (verdict: Accepted):
N, K = map(int, input().split())
p = list(map(int, input().split()))
p = sorted(p)

ans = 0
for i in range(K):
  ans += p[i]

print(ans)

Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
N, K = map(int, input().split())
A = list(map(int, input().split()))

A.sort(reverse = True)
min = 0

for i in range(K):
  min += A[i]
  
print(min)

Failing test case input:
3 3
83 001 130 120 145

Expected output:
204


Actual output:
395


Fixed submission (verdict: Accepted):
N, K = map(int, input().split())
A = list(map(int, input().split()))

A.sort()
min = 0

for i in range(K):
  min += A[i]
  
print(min)

Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
N,K= map(int, input().split())
p = list(map(int, input().split()))

print(sum(sorted(p)[:N]))

Failing test case input:
5 2
68 001 80 156 65

Expected output:
66


Actual output:
370


Fixed submission (verdict: Accepted):
n,k = map(int, input().split())
p = list(map(int, input().split()))

print(sum(sorted(p)[:k]))

Problem: p02628
Buggy submission (PyPy3 (7.3.0), verdict: Wrong Answer):
n,k = map(int,input().split())
p = list(map(int,input().split()))

p = sorted(p,reverse=True)
ans = 0
for i in range(k):
  ans += p[i]
print(ans)

Failing test case input:
1 4
37 000 4 -2 126

Expected output:
39


Actual output:
167


Fixed submission (verdict: Accepted):
n,k = map(int,input().split())
p = list(map(int,input().split()))

p = sorted(p)
ans = 0
for i in range(k):
  ans += p[i]
print(ans)

Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
n,k=map(int,input().split())
p=list(map(int,input().split()))
p=sorted(p)
a=0
for i in range(k-1):
  a+=p[i]
print(a)

Failing test case input:
5 3
54 100 80 16 17

Expected output:
87


Actual output:
33


Fixed submission (verdict: Accepted):
n,k=map(int,input().split())
p=list(map(int,input().split()))
p=sorted(p)
a=0
for i in range(k):
  a+=p[i]
print(a)

Problem: p02628
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
N,K = map(int,input().split())

p=list(map(int,input().split()))

p.sort()
print(p)

sum = 0

for i in range(K):
    print(i)
    sum += p[i]
    
    
print(sum)

Failing test case input:
5 3
50 100 80 120 150

Expected output:
230


Actual output:
[50, 80, 100, 120, 150]
0
1
2
230


Fixed submission (verdict: Accepted):
N,K = map(int,input().split())

p=list(map(int,input().split()))
p.sort()

sum = 0

for i in range(K):
    sum += p[i]
    
    
print(sum)
Problem: p03605
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
N = list(input())
print("Yes" if N[0] == 9 or N[1] == 9 else "No")

Failing test case input:
929

Expected output:
Yes


Actual output:
No


Fixed submission (verdict: Accepted):
N = list(input())
print("Yes" if N[0] == "9" or N[1] == "9" else "No")

Problem: p03605
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
N = input()
if N[0] ==9 or N[1] == 9:
    print("Yes")
else:
    print("No")

Failing test case input:
929

Expected output:
Yes


Actual output:
No


Fixed submission (verdict: Accepted):
N = input()
if N[0] =="9" or N[1] == "9":
    print("Yes")
else:
    print("No")

Problem: p03605
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
a = input()
a.find("9")
if a != -1:
    print("Yes")
else:
    print("No")

Failing test case input:
1223

Expected output:
No


Actual output:
Yes


Fixed submission (verdict: Accepted):
a = input()
if a.find("9") != -1:
    print("Yes")
else:
    print("No")

Problem: p03605
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
import sys

stdin = sys.stdin
 
ri = lambda: int(rs())
rl = lambda: list(map(int, stdin.readline().split()))
rs = lambda: stdin.readline().rstrip()  

N = ri()
print('Yes' if str(N).find('9') else 'No')


Failing test case input:
929

Expected output:
Yes


Actual output:
No


Fixed submission (verdict: Accepted):
import sys

stdin = sys.stdin
 
ri = lambda: int(rs())
rl = lambda: list(map(int, stdin.readline().split()))
rs = lambda: stdin.readline().rstrip()  

N = ri()
print('Yes' if str(N).find('9') >= 0 else 'No')

Problem: p03605
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
a = input()
a.find("9")
if a == 0 or a == 1:
    print("Yes")
else:
    print("No")

Failing test case input:
929

Expected output:
Yes


Actual output:
No


Fixed submission (verdict: Accepted):
a = input()
if a.find("9") != -1:
    print("Yes")
else:
    print("No")

Problem: p03605
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
N=list(input())
print(N)
if N[0]=='9' or N[1]=='9':
    print('Yes')
else:
    print('No')


Failing test case input:
929

Expected output:
Yes


Actual output:
['9', '2', '9']
Yes


Fixed submission (verdict: Accepted):
N=list(input())
if N[0]=='9' or N[1]=='9':
    print('Yes')
else:
    print('No')

Problem: p03605
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
N = input()
if "9" in N:
    print("YES")
else:
    print("NO")

Failing test case input:
929

Expected output:
Yes


Actual output:
YES


Fixed submission (verdict: Accepted):
N = input()
if "9" in N:
    print("Yes")
else:
    print("No")

Problem: p03605
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
N = input()

if N[0] == 9 or N[1] == 9:
  print("Yes")
else:
  print("No")

Failing test case input:
929

Expected output:
Yes


Actual output:
No


Fixed submission (verdict: Accepted):
N = input()

if N[0] == "9" or N[1] == "9":
  print("Yes")
else:
  print("No")
Problem: p03605
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
s=input()
if s[0:1]==9 or s[1:2]==9:
  print("Yes")
else:
  print("No")
  

Failing test case input:
929

Expected output:
Yes


Actual output:
No


Fixed submission (verdict: Accepted):
s=input()
if s[0]=="9" or s[1]=="9":
  print("Yes")
else:
  print("No")

Problem: p03605
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
print("YES" if ("9" in list(input())) else "NO")

Failing test case input:
929

Expected output:
Yes


Actual output:
YES


Fixed submission (verdict: Accepted):
print("Yes" if ("9" in list(input())) else "No")

Problem: p03605
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
a=list(input())
if a[0]==9 or a[1]==9:
  print("Yes")
else:
  print("No")


Failing test case input:
929

Expected output:
Yes


Actual output:
No


Fixed submission (verdict: Accepted):
a=list(input())
if a[0]!="9" and a[1]!="9":
  print("No")
else:
  print("Yes")

Problem: p03605
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
a = input()
a.find("9")
if not a == -1:
    print("Yes")
else:
    print("No")

Failing test case input:
1223

Expected output:
No


Actual output:
Yes


Fixed submission (verdict: Accepted):
a = input()
if a.find("9") != -1:
    print("Yes")
else:
    print("No")

Problem: p03605
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
n = input()
 
if n[0] == 9 or n[1] == 9:
  print("Yes")
else:
  print("No")

Failing test case input:
929

Expected output:
Yes


Actual output:
No


Fixed submission (verdict: Accepted):
n = input()
 
if n[0] == "9" or n[1] == "9":
  print("Yes")
else:
  print("No")

Problem: p03605
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
s=str(input())

f=0
for a in s:
    if a=='9':
        f=1
if f==1:
    print('Yes')
else:
    print('NO')

Failing test case input:
1223

Expected output:
No


Actual output:
NO


Fixed submission (verdict: Accepted):
s=str(input())

f=0
for a in s:
    if a=='9':
        f=1
if f==1:
    print('Yes')
else:
    print('No')

Problem: p03605
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
n = input()

if n[0] == 9 or n[1] == 9:
  prnit("Yes")
else:
  print("No")

Failing test case input:
929

Expected output:
Yes


Actual output:
No


Fixed submission (verdict: Accepted):
n = input()
 
if n[0] == "9" or n[1] == "9":
  print("Yes")
else:
  print("No")

Problem: p03605
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
n = str(input())
cnt = 0
for i in n:
  if n == "9":
    cnt += 1
if cnt >= 1:
    print("Yes")
else:
    print("No")

Failing test case input:
929

Expected output:
Yes


Actual output:
No


Fixed submission (verdict: Accepted):
n = str(input())
cnt = 0
for i in n:
    if i == "9":
       cnt += 1
if cnt >= 1:
    print("Yes")
else:
    print("No")
Problem: p03605
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
s=input()
ans=False
for i in s:
  if i=='9':
    ans=False

if ans:
  print('Yes')
else :
    print('No')

Failing test case input:
929

Expected output:
Yes


Actual output:
No


Fixed submission (verdict: Accepted):
s=input()
ans=False
for i in s:
  if i=='9':
    ans=True

if ans:
  print('Yes')
else :
    print('No')

Problem: p03605
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
s = input()
if s[0] == 9 or s[1] == 9:
  print('No')
else:
  print('Yes')

Failing test case input:
1223

Expected output:
No


Actual output:
Yes


Fixed submission (verdict: Accepted):
s = input()
if s[0] == '9' or s[1] == '9':
  print('Yes')
else:
  print('No')

Problem: p03605
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
c = input()
if c in "9":
  print("Yes")
else:
  print("No")

Failing test case input:
929

Expected output:
Yes


Actual output:
No


Fixed submission (verdict: Accepted):
c = input()
if "9" in c:
  print("Yes")
else:
  print("No")

Problem: p03605
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
N = input()
if "9" in "N":
    print("YES")
else:
    print("NO")

Failing test case input:
1223

Expected output:
No


Actual output:
NO


Fixed submission (verdict: Accepted):
N = input()
if "9" in N:
    print("Yes")
else:
    print("No")

Problem: p03605
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
N=str(input())
if N[0]=='9' or N[1]=='9':
  print('Yes')
else:
  print('NO')

Failing test case input:
1223

Expected output:
No


Actual output:
NO


Fixed submission (verdict: Accepted):
N=str(input())
if N[0]=='9' or N[1]=='9':
  print('Yes')
else:
  print('No')

Problem: p03605
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
N = input()
flag = 0

for i in range(len(N)):
    if N[i] == '9':
        print('Yes')
        flag = 1
if flag == 0:
    print('No')

Failing test case input:
929

Expected output:
Yes


Actual output:
Yes
Yes


Fixed submission (verdict: Accepted):
N = input()
flag = 0
 
for i in range(len(N)):
    if N[i] == '9':
        print('Yes')
        flag = 1
        break
if flag == 0:
    print('No')

Problem: p03605
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
a = input()
if "9" in a:
  print("Yes")
else :
  print("NO")


Failing test case input:
1223

Expected output:
No


Actual output:
NO


Fixed submission (verdict: Accepted):
a = input()
if "9" in a:
  print("Yes")
else :
  print("No")

Problem: p03605
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
N=map(str,input().replace("",",").split())
if "9" in N:
    print("Yes")
else:
    print("No")

Failing test case input:
929

Expected output:
Yes


Actual output:
No


Fixed submission (verdict: Accepted):
N=map(str,input().replace(""," ").split())
if "9" in N:
    print("Yes")
else:
    print("No")

Problem: p03605
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
s=input()
if s[:1]==9 or s[-1:]==9:
  print("Yes")
else:
  print("No")
  

Failing test case input:
929

Expected output:
Yes


Actual output:
No


Fixed submission (verdict: Accepted):
s=input()
if s[0]=="9" or s[1]=="9":
  print("Yes")
else:
  print("No")