logo

Crowdly

After a successful call to the original function , a student adds:   pr...

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

After a successful call to the original function, a student adds: 

print(total) 

outside the function. 

They argue: “The function has run, so total now exists and can be printed here.” 

Explain why this reasoning is incorrect, and identify which variable outside the function holds the returned mean. [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!