Question: Add data validation to the program segment of Exercise 35 to check that the user enters only positive integer values. Data from Exercise 35 Write

Add data validation to the program segment of Exercise 35 to check that the user enters only positive integer values.


Data from Exercise 35

Write pseudocode that will average a list of numbers input by the user. Use the following variables:

● Number As Integer

● Sum As Integer

● Average As Float

● Count As Integer

Also:

● Use a While loop to enter the numbers.

● Use a sentinel to test when the user wants to stop entering numbers.

● Assume the user enters valid data.

Step by Step Solution

3.40 Rating (166 Votes )

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock

Declare Number As Integer Declare Sum As Integer D... 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 Prelude to Programming Questions!