Goldman Sachs Interview Question

Q: A prefix sum DSA question