COMP 110-003 Fall 2008

Lab 4

25 points

Assigned: Friday, September 19
Due: Friday, September 26 Wednesday, October 1 by 2:00pm

Description

Lab 4 will give you practice with writing a loop. Write a program that reads in a list of UNC basketball scores (nonnegative integers!) one at a time from the user and outputs the following statistics:

  1. Total number of games
  2. Total number of games scoring at least 90 points
  3. Percentage of games scoring at least 90 points
  4. Average game score
  5. Range of scores: lowest and highest

The end of the input is indicated by the user entering a negative sentinel value. See p. 183 (4th edition) or p. 207 (5th edition) for details. Note that the sentinel value is not used in computing the highest, lowest or average game score.

Suggestions for starting the assignment:

Additional Questions

How to turn in the assignment

Grading