Functions nested functions (solution)

Exercise
Output solution
[1] 17055.37