Header: Mean_IT_Scores
Declaration:
The purpose of this algorithm is to accept a set of IT test scores and calculate the mean
(average) score. The program should terminate when the word “finished” is entered.
Variables:
score_string of string
score of real
total of real
count of integer
mean of real
Step 1: Start
Step 2: Write (“Enter IT score or type ‘finished’ to end”)
Step 3: Read Status
Step 4: Set total ← 0
Step 5: Set count ← 0
Step 6: While (status <> ‘finished’) do
6i. Write (‘Please input the score’)
6ii. Read score
6iii. Set count ← count + 1
6iv. Set total ← (total + score)
6iv. Write (“Enter next IT score or type ‘finished’ to end”)
6v. Read status
End While
Step 7: Set mean ← (total / count)
Step 8: Print (“The mean score is “, mean)
Step 9: Stop