Domanda di colloquio di Visa Inc.

Write a reduce function, both with and without recursion.