iT邦幫忙

鐵人檔案

2022 iThome 鐵人賽
回列表
自我挑戰組

LeetCode Top 100 Liked 系列

本題庫取自 CSDN (https://blog.csdn.net/fuxuemingzhu/article/details/119514856)
LeetCode Liked 數最多的 100 道題目,難度主要介於 Medium ~ Easy 之間。本系列用意為期許自己在工作之餘也別忘了練習基礎資料結構和演算法解題~

鐵人鍊成 | 共 77 篇文章 | 11 人訂閱 訂閱系列文 RSS系列文

[Day 51] Move Zeroes (Easy)

283. Move Zeroes Solution 1: Two Pointers class Solution: def moveZeroes(sel...

2022-11-05 ‧ 由 JC 分享

[Day 52] Linked List Cycle (Easy)

141. Linked List Cycle Solution 1: Hash class Solution: def hasCycle(self, h...

2022-11-06 ‧ 由 JC 分享

[Day 53] Validate Binary Search Tree (Medium)

98. Validate Binary Search Tree Solution 1: DFS class Solution: def _isValid...

2022-11-07 ‧ 由 JC 分享

[Day 54 - 1] Binary Tree Maximum Path Sum (Hard)

124. Binary Tree Maximum Path Sum Solution 1: DFS + Recursive # Definition for a...

2022-11-08 ‧ 由 JC 分享

[Day 54 - 2] Construct Binary Tree from Preorder and Inorder Traversal (Medium)

105. Construct Binary Tree from Preorder and Inorder Traversal Solution 1: Recur...

2022-11-08 ‧ 由 JC 分享

[Day 55] Find First and Last Position of Element in Sorted Array (Medium)

34. Find First and Last Position of Element in Sorted Array Solution 1: Recursiv...

2022-11-09 ‧ 由 JC 分享

[Day 56] Sliding Window Maximum (Hard)

239. Sliding Window Maximum (Hard) Solution 1: Brute Force Time Complexity: O()...

2022-11-10 ‧ 由 JC 分享

[Day 57] Linked List Cycle II (Medium)

142. Linked List Cycle II Solution 1: HashSet class Solution: def detectCycl...

2022-11-11 ‧ 由 JC 分享

[Day 58] Word Break (Medium)

139. Word Break Solution 1: DFS (TLE) class Solution: def wordBreak(self, s:...

2022-11-12 ‧ 由 JC 分享

[Day 59] Jump Game II (Medium)

45. Jump Game II Solution 0: Brute-Force + DP (看完題目第一個想法) class Solution: de...

2022-11-13 ‧ 由 JC 分享