Beginner
Average of any number of values
Write average(*numbers) that returns the mean of all the arguments (their sum divided by how many there are). With no arguments it returns 0.
Replace the return None line with your code. The last line of the starter already prints average(2, 4, 9), which should show 5.0.
What Check tests
average(2, 4, 9)is 5.0average()is 0average(7)is 7- Spreading a list works
- Floats and negatives work
Stuck? One hint at a time
The solution unlocks after your first Check. Try first: that is where the learning happens.
main.py
Sign in to run your code.
Output
Press Run to see what your program prints.