0% found this document useful (0 votes)
5 views1 page

Calculate Mean IT Test Scores

This document outlines an algorithm for calculating the mean of a set of IT test scores, terminating when the user inputs 'finished'. It details the steps for initializing variables, reading scores, updating totals and counts, and finally computing and displaying the mean score. The algorithm includes user prompts for input and handles the termination condition effectively.

Uploaded by

Daivya Jagmohan
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
5 views1 page

Calculate Mean IT Test Scores

This document outlines an algorithm for calculating the mean of a set of IT test scores, terminating when the user inputs 'finished'. It details the steps for initializing variables, reading scores, updating totals and counts, and finally computing and displaying the mean score. The algorithm includes user prompts for input and handles the termination condition effectively.

Uploaded by

Daivya Jagmohan
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd

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

You might also like