Concept Flow - np.cumsum() for cumulative sum
Start with array
Initialize sum = 0
Take next element
Add element to sum
Store sum in output array
More elements?
Yes→Take next element
No
Return cumulative sum array
np.cumsum() takes an array and adds elements one by one, storing the running total at each step, returning an array of these sums.