Modularisation Ex 2 - Calculate Average

Created By: M Ritter | Difficulty Level: 3

Description

An algorithm is required to ask the user to input three values. These values are then passed to a module that will calculate and return the average.

Drag from here

    Construct your solution here

    • BEGIN
    • INPUT num1
    • INPUT num2
    • INPUT num3
    • SET result = CALL findAverage(num1, num2, num3)
    • DISPLAY result
    • END
    • BEGIN findAverage(x, y, z)
    • CALCULATE total = x + y + z
    • CALCULATE average = total / 3
    • RETURN average
    • END findAverage