Computer Science, asked by aloziesther, 5 months ago

Develop an algorithm that will calculate the average of five numbers​

Answers

Answered by valeriy69
4

\huge\red{\mid{\fbox{\tt{Using\: Python\: 3}}\mid}}

def avg(nums):

A = min(nums)

d = [n - A for n in nums]

return A + (sum(d) / len(nums))

print("Average:", avg((nums := list(map(int, input("nums: ").split())))))

\large\mathsf\color{lightgreen}useful?\: \color{white}\longrightarrow\: \color{orange}brainliest!

Similar questions