Design and write a TOM simulator program to perform the following tasks:
1.Enter a list of positive integers, terminated by zero.
2.Output a count of the numbers
3.Output the sum of the numbers.
4.Output the mean of the numbers
5.Output the smallest number in the list
6.Output the largest number in the list
Thus for the following list: 4 2 8 10 6 0
The output should be:
5
30
6
2
10
N.B. the list is of variable length, e.g. it could have 1, 2, 3, 4, 5,
6, 7, 8, etc. numbers in it, the only constant is that the number 0
terminates it.
Design program design using flowchart
Program documentation, in terms of a print out of the program,
annotated to explain how it works.
Design and evidence of appropriate testing |