Skip to content

Above average

Above average

Two loops, one after the other: the first works out the average, the second keeps the numbers above it.

This joins two patterns you have already used, the running total and the filter. Solving a problem in stages like this is how most longer programs are built.

Log in or create account

IGCSE, A-Level & AP