1 / 23 Settings
<<<>>>

This animation shows the steps of an algorithm to add together and print the values in a list. This animation is an example of the accumulate pattern. The values in the list to be the price of items being purchased.

Created with Raphaƫl 2.1.2
  1. 4
  2. 13
  3. 6
  4. 9
  5. 11
set
total
=
0
for each item
price
do
set
total
=
total + price
print (total)
STATE
price
total
CONSOLE
Proficient Saving... Error Saving
Server Error
Resubmit