摘要:
https://blog.csdn.net/cetrol_chen/article/details/91129806 阅读全文
posted @ 2020-12-21 16:02
ChevisZhang
阅读(64)
评论(0)
推荐(0)
摘要:
class Solution: def maxCoins(self, nums: List[int]) -> int: # DP 因为dp[left][right] = argmax(dp[left][i]+dp[i][right]+left*i*right) # 这个遍历顺序就是,先中间,后两边 阅读全文
posted @ 2020-12-21 15:13
ChevisZhang
阅读(129)
评论(0)
推荐(0)
摘要:
https://leetcode-cn.com/problems/word-break-ii/ class Solution: def wordBreak(self, s: str, wordDict: List[str]) -> List[str]: # 本题就是加上剪枝的回溯算法 # recor 阅读全文
posted @ 2020-12-21 10:04
ChevisZhang
阅读(88)
评论(0)
推荐(0)

浙公网安备 33010602011771号