Visa Inc. interview question

Write a reduce function, both with and without recursion.