1 题目描述
2 解题思路
class Solution:
def runningSum(self, nums: List[int]) -> List[int]:
num=0
lst=[]
for i in nums:
num+=i
lst.append(num)
return(lst)
class Solution:
def runningSum(self, nums: List[int]) -> List[int]:
num=0
lst=[]
for i in nums:
num+=i
lst.append(num)
return(lst)