What's Wrong?

question -->Contest Page | CodeChef
my solution–>:

for _ in range(int(input())):
n,k = map(int,input().split())
arr = list(map(int,input().split()))
rej = arr.count(-1)
if (n-rej>ceil(n/2)):
print (“Rejected”)
for i in arr:
if (i>k):
max +=1
if (i<k):

    if (max>=1):
        print ("Too Slow")
    elif (min==len(arr))&(rej==0):
        print ("Bot")
        print ("Accepted")

The variable rej stores how many problems were not solved by the candidate.
Therefore n-rej stores how many problems were solved by the candidate.

if (n-rej>ceil(n/2)):
print (“Rejected”)

Why are you rejecting when someone solves more problems than N/2?

1 Like

ohh got it bro thanks for your help.