Write a program which repeatedly reads several people's height numbers in cm(centimeter) until the user enters "done". Once "done" is entered, print out the max, min, and average of the height...

Write a program which repeatedly reads several people's height numbers in cm(centimeter) until the user enters "done". Once "done" is entered, print out the max, min, and average of the height numbers. Correct height data should be number between 50cm and 250cm. If the user enters number out of the range, or anything other than a number, detect the mistake and print an error message and skip to the next number. Sample input and output: Enter a height: 300 Invalid input Enter a height: 10 Invalid input Enter a height: 200 Enter a height: good Invalid input Enter a height: 180 Enter a height: 165 Enter a height: done Max: 200.0 Min: 165.0 Average: 181.67

Jun 09, 2022
SOLUTION.PDF

Get Answer To This Question

Related Questions & Answers

More Questions »

Submit New Assignment

Copy and Paste Your Assignment Here