Leetcode 5453. Running Sum of 1d Array

In this Leetcode problem, we are asked to return the sum array given an nums array where sum[i] = sum(nums[0],…, nums[i])

Problem statement


A few ideas for this problem:

  1. We will use the input array and modify it, and return it as the solution. That way, we don’t have to create a new array.
  2. We will build a loop such that…