Question: Functional programming with reduce() and Recursion. We looked at N factorial or N! as the product of all numbers from 1 to N.
(a)Take a minute to write a small, simple function called mult(x, y) that takes x and y and returns their product.
(b) Use the mult() function you created in part (a)along with reduce() to calculate factorials.
(c) Discard the use of mult() completely and use a lambda expression instead.
(d) In this chapter, we presented a recursive solution to finding N! Use the timeit() function you completed in the problem above and time all three versions of your factorial function (iterative, reduce(), and recursive). Explain any differences in performance, anticipated and actual.