Question: 3. Implement the function total() that takes in a number as a parameter. The function will repeat asking the user to enter a number

3. Implement the function total() that takes in a number as a parameter. The function will repeat asking the

3. Implement the function total() that takes in a number as a parameter. The function will repeat asking the user to enter a number based on the number passed in. The function will collect all the numbers a user enters and return the total of all the number. The function will print the contents of the list to the screen before it returns the total The output must match the screenshots. You must convert the value the user enters a number. The information below shows how you would call the function total () and what it would display for a few different inputs: total (5) Please enter a number: 1 Please enter a number: 2 Please enter a number: 3 Please enter a number: 4 Please enter a number: 5 Numbers entered: [1, 2, 3, 4, 5] 15 total (0) Numbers entered: [] 0 total (3) Please enter a number: 100 Please enter a number: 200 Please enter a number: 300 Numbers entered: [100, 200, 300] 600

Step by Step Solution

3.51 Rating (154 Votes )

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock

The question provides details about a function called total that takes an integer as a parameter Thi... View full answer

blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!