Deals Of The Week - hours only!Up to 80% off on all courses and bundles.-Close
Introduction
Quiz
4. Question 3
Summary

Instruction

Perfect! How about loops?

Exercise

Write a program that finds the arithmetic mean (average value) of all the numbers provided by the user:

  • Start by asking the user: How many numbers do you have?
  • Keep asking the user to provide additional numbers by showing Provide a number:
  • Once you have all numbers, print: The average is {average_value}

Stuck? Here's a hint!

Ask the user how many numbers they're going to provide. Store this information in a variable named count_numbers. Then, create a loop like this:

for i in range(0, count_numbers):