1: 主要思想:dp(最大和子数组) class Solution(object): def maxProfit(self, prices): """ :type prices: List[int] :rtype: int """ lenth = len(prices) if lenth == 1 or lenth == 0: return 0 newlst = [] for i in range(1,lenth):
评论星级较低,若资源使用遇到问题可联系上传者,3个工作日内问题未解决可申请退款~