Running Totals

The running total algorithm uses a loop and variable (often called 'total'). It keeps adding to the total until the end of the loop, then shows the final values.

Task 5 (Running Total in a Loop)

The self-service checkout uses a loop to get each price from the sensor, then adds up the total and shows it on the screen.

Reset Get feedback

Next task