LeetCode

912. Sort an Array

912. Sort an Array Merge Sort (Accepted) class Solution: def

383. Ransom Note

383. Ransom Note class Solution: def canConstruct(self, ransomNote: str,

186. Reverse Words in a String II

186. Reverse Words in a String II 這個題目是 Reverse Words

557. Reverse Words in a String III

557. Reverse Words in a String III 這一題如果掌握了 151. Reverse

119. Pascal's Triangle II

119. Pascal's Triangle II class Solution: def getRow(

118. Pascal's Triangle

118. Pascal's Triangle class Solution: def generate(self,

151. Reverse Words in a String

151. Reverse Words in a String 題目是給定一個字串,這個字串的模式是,這個字串很像是一個句子,但是是由多個單字以及「

561. Array Partition

561. Array Partition class Solution: def arrayPairSum(self, nums: List[

210. Course Schedule II

210. Course Schedule II Check 207. Course Schedule

207. Course Schedule

207. Course Schedule 這一個題目的設計滿巧秒的,我個人覺得這個題目綜合了樹的遍歷(遞迴)、回溯法、動態規劃以及資料與圖形轉換的設計,外加上題目可以套用在各種現實生活問題中。所以整體而言