Skip to content

Commit cd81271

Browse files
committed
LeetCode: 1480 solved
1 parent 8e83300 commit cd81271

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
# https://leetcode.com/problems/running-sum-of-1d-array/
2+
3+
class Solution:
4+
def runningSum(self, nums: [int]) -> [int]:
5+
for i in range(1, len(nums)):
6+
nums[i] += nums[i - 1]
7+
return nums

0 commit comments

Comments
 (0)