logo

Crowdly

A student wants to calculate:   result = mean( [2, 4, 9]) + 1   T...

✅ The verified answer to this question is available below. Our community-reviewed solutions help you understand the material better.

A student wants to calculate: 

result = mean([2, 4, 9]) + 1 

They suggest replacing the function’s final line with: 

print(total / len(values)) 

Explain why printing the mean is not a suitable replacement for returning it in this use of the function. [2 marks] 

More questions like this

Want instant access to all verified answers on moodle1.maths.ed.ac.uk?

Get Unlimited Answers To Exam Questions - Install Crowdly Extension Now!