Académique Documents
Professionnel Documents
Culture Documents
Objectives
• A program is required to
read three numbers, add
them together and print
their total
• Tackle this problem in two
stages
• First, underline the nouns
and adjectives used in the
specification Input Processing Output
• A program is required to Number1 Total
read three numbers, add
them together and print Number2
their total Number3
Defining diagram
Input Processing Output
number1 10 40
number3 30 42
total = number1 + number2 +
number 3
Print total
Expected Results
Print total 2 60
END 3 Print
Second pass
1 40 41 42
2 123
3 Print
• Answer outline:
– Define problem by constructing a defining diagram
– Create a solution algorithm using pseudocode
– Desk check the solution algorithm using two valid cases
• Answer outline:
– Define problem by constructing a defining diagram
– Create a solution algorithm using pseudocode
– Desk check the solution algorithm using two valid cases