fold
A list method that adds things up. It starts from an initial value and calls your function once per item with the running total and the item.
A list method that adds things up. It starts from an initial value and calls your function once per item with the running total and the item.