Your school is going to start a new scholarship program. To apply for this scholarship you have to w…
Click here to read the complete problem statement.
If you need help solving this problem, mention your approach and ask specific questions. Please avoid sharing your code and asking the Community to figure out “what’s wrong”.
a = list(map(int,input().strip().split()))
n=int(input())
le = len(a)
avg = n/le
for i in range(len(a)):
if a[i]<avg:
sub = le-1
n = n - a[i]
result = n/sub
print("%.2f"%result)
inputArr = list(map(int, input().split()))
total = int(input())
avg = total / len(inputArr)
count = 0
for i in inputArr:
if i < avg:
total -= i
count+=1
avg = total / (len(inputArr)-count)
print('%.2f'%avg)
wrong answer on test case 4,
can anybody tell me, why?