Add sum of all previous elements in array (DPFCI_1.2)

This question is from exercise in my book Dynamic Programming for Coding Interviews (Question: 1.2, Page-5) Question: Given an array, arr of integers, write a recursive function that add sum of all the previous numbers to each index of the array. For example, if the input array is {1, 2, 3, 4, 5, 6} then […]