Menu

[Solved]-Python Code Get Help Fixing Filter Map Functions Descriptions Included Need Help Goes Para Q37181287

* This is my python code, can I get some help fixing my filter()and map() functions? descriptions are included i just need helpwith what goes in the pararenthesis

from functools import reduce

scores = [25, 56, 79, 94, 99]
print(“Initial scores are: ” + str(scores))

total_scores = reduce(lambda a,b : a+b,scores)

average = total_scores/len(scores)
print(“Sum of all scores: ” + str(total_scores))
print(“Average: ” + str(average))

# use filter to figure scores that are above average
above_avg = filter()
print(“Scores above average: ” + str(list(above_avg)))

curved_scores = map() #map the scores list by adding 5 to each itemin the list
print(“Curved scores are: ” + str(list(curved_scores)))

Expert Answer


Answer to * This is my python code, can I get some help fixing my filter() and map() functions? descriptions are included i just n… . . .

OR


Leave a Reply

Your email address will not be published. Required fields are marked *