LeetCode刷题计划
Array
基础
题号 | 题目名称 | 状态 |
---|---|---|
27 | Remove Element | |
26 | Remove Duplicates from Sorted Array | |
80 | Remove Duplicates from Sorted Array II | |
277 | Find the Celebrity | |
189 | Rotate Array | |
41 | First Missing Positive | |
299 | Bulls and Cows | |
134 | Gas Station | |
118 | Pascal’s Triangle | |
119 | Pascal’s Triangle II | |
169 | Majority Element | |
229 | Majority Element II | |
274 | H-Index | |
275 | H-Index II | |
243 | Shortest Word Distance | |
244 | Shortest Word Distance II | |
245 | Shortest Word Distance III | |
217 | Contains Duplicate | |
219 | Contains Duplicate II | |
220 | Contains Duplicate III | |
55 | Jump Game | |
45 | Jump Game II | |
121 | Best Time to Buy and Sell Stock | |
122 | Best Time to Buy and Sell Stock II | |
123 | Best Time to Buy and Sell Stock III | |
188 | Best Time to Buy and Sell Stock IV | |
309 | Best Time to Buy and Sell Stock with Cooldown | |
11 | Container With Most Water | |
42 | Trapping Rain Water | |
334 | Increasing Triplet Subsequence | |
128 | Longest Consecutive Sequence | |
164 | Maximum Gap | |
287 | Find the Duplicate Number | |
135 | Candy | |
330 | Patching Array |
提高
题号 | 题目名称 | 状态 |
---|---|---|
4 | Median of Two Sorted Arrays | |
321 | Create Maximum Number | |
327 | Count of Range Sum | |
289 | Game of Life |
Interval
题号 | 题目名称 | 状态 |
---|---|---|
57 | Insert Interval | |
56 | Merge Intervals | |
252 | Meeting Rooms | |
253 | Meeting Rooms II | |
352 | Data Stream as Disjoint Intervals |
Counter
题号 | 题目名称 | 状态 |
---|---|---|
239 | Sliding Window Maximum | |
295 | Find Median from Data Stream | |
53 | Maximum Subarray | |
325 | Maximum Size Subarray Sum Equals k | |
209 | Minimum Size Subarray Sum | |
238 | Product of Array Except Self | |
152 | Maximum Product Subarray | |
228 | Summary Ranges | |
163 | Missing Ranges | |
88 | Merge Sorted Array | |
75 | Sort Colors | |
283 | Move Zeroes | |
376 | Wiggle Subsequence | |
280 | Wiggle Sort | |
324 | Wiggle Sort II | |
278 | First Bad Version | |
35 | Search Insert Position | |
33 | Search in Rotated Sorted Array | |
81 | Search in Rotated Sorted Array II | |
153 | Find Minimum in Rotated Sorted Array | |
154 | Find Minimum in Rotated Sorted Array II | |
162 | Find Peak Element | |
374 | Guess Number Higher or Lower | |
34 | Find First and Last Position of Element in Sorted Array | |
349 | Intersection of Two Arrays | |
350 | Intersection of Two Arrays II | |
315 | Count of Smaller Numbers After Self | |
300 | Longest Increasing Subsequence | |
354 | Russian Doll Envelopes |
String
基础
题号 | 题目名称 | 状态 |
---|---|---|
28 | Implement strStr() | |
14 | Longest Common Prefix | |
58 | Length of Last Word | |
387 | First Unique Character in a String | |
383 | Ransom Note | |
344 | Reverse String | |
151 | Reverse Words in a String | |
186 | Reverse Words in a String II | |
345 | Reverse Vowels of a String | |
205 | Isomorphic Strings | |
293 | Flip Game | |
294 | Flip Game II | |
290 | Word Pattern | |
242 | Valid Anagram | |
49 | Group Anagrams | |
249 | Group Shifted Strings | |
87 | Scramble String | |
179 | Largest Number | |
6 | ZigZag Conversion | |
161 | One Edit Distance | |
38 | Count and Say | |
358 | Rearrange String k Distance Apart | |
316 | Remove Duplicate Letters | |
271 | Encode and Decode Strings | |
168 | Excel Sheet Column Title | |
171 | Excel Sheet Column Number | |
13 | Roman to Integer | |
12 | Integer to Roman | |
273 | Integer to English Words | |
246 | Strobogrammatic Number | |
247 | Strobogrammatic Number II | |
248 | Strobogrammatic Number III |
提高
题号 | 题目名称 | 状态 |
---|---|---|
157 | Read N Characters Given Read4 | |
158 | Read N Characters Given Read4 II - Call multiple times | |
68 | Text Justification | |
65 | Valid Number |
Substring
题号 | 题目名称 | 状态 |
---|---|---|
76 | Minimum Window Substring | |
30 | Substring with Concatenation of All Words | |
3 | Longest Substring Without Repeating Characters | |
340 | Longest Substring with At Most K Distinct Characters | |
395 | Longest Substring with At Least K Repeating Characters | |
159 | Longest Substring with At Most Two Distinct Characters |
Palindrome
题号 | 题目名称 | 状态 |
---|---|---|
125 | Valid Palindrome | |
266 | Palindrome Permutation | |
5 | Longest Palindromic Substring | |
9 | Palindrome Number | |
214 | Shortest Palindrome | |
336 | Palindrome Pairs | |
131 | Palindrome Partitioning | |
132 | Palindrome Partitioning II | |
267 | Palindrome Permutation II |
Parentheses
题号 | 题目名称 | 状态 |
---|---|---|
20 | Valid Parentheses | 点击查看 |
22 | Generate Parentheses | 点击查看 |
32 | Longest Valid Parentheses | 点击查看 |
241 | Different Ways to Add Parentheses | |
301 | Remove Invalid Parentheses |
Subsequence
题号 | 题目名称 | 状态 |
---|---|---|
392 | Is Subsequence | |
115 | Distinct Subsequences | |
187 | Repeated DNA Sequences |
Math
基础
题号 | 题目名称 | 状态 |
---|---|---|
7 | Reverse Integer | |
165 | Compare Version Numbers | |
66 | Plus One | |
8 | String to Integer (atoi) | |
258 | Add Digits | |
67 | Add Binary | |
43 | Multiply Strings | |
29 | Divide Two Integers | |
69 | Sqrt(x) | |
50 | Pow(x, n) | |
367 | Valid Perfect Square | |
365 | Water and Jug Problem | |
204 | Count Primes |
Sum
题号 | 题目名称 | 状态 |
---|---|---|
1 | Two Sum | |
167 | Two Sum II - Input array is sorted | |
15 | 3Sum | |
16 | 3Sum Closest | |
259 | 3Sum Smaller | |
18 | 4Sum |
冷门
题号 | 题目名称 | 状态 |
---|---|---|
231 | Power of Two | |
326 | Power of Three | |
342 | Power of Four | |
372 | Super Pow | |
233 | Number of Digit One | |
319 | Bulb Switcher | |
292 | Nim Game | |
202 | Happy Number | |
400 | Nth Digit | |
263 | Ugly Number | |
264 | Ugly Number II | |
306 | Additive Number | |
172 | Factorial Trailing Zeroes | |
343 | Integer Break | |
396 | Rotate Function | |
390 | Elimination Game | |
386 | Lexicographical Numbers | |
357 | Count Numbers with Unique Digits | |
360 | Sort Transformed Array | |
397 | Integer Replacement | |
368 | Largest Divisible Subset |
Tree
基础
题号 | 题目名称 | 状态 |
---|---|---|
144 | Binary Tree Preorder Traversal | |
94 | Binary Tree Inorder Traversal | |
145 | Binary Tree Postorder Traversal | |
102 | Binary Tree Level Order Traversal |
Preorder
题号 | 题目名称 | 状态 |
---|---|---|
100 | Same Tree | |
101 | Symmetric Tree | |
226 | Invert Binary Tree | |
257 | Binary Tree Paths | |
112 | Path Sum | |
113 | Path Sum II | |
129 | Sum Root to Leaf Numbers | |
298 | Binary Tree Longest Consecutive Sequence | |
111 | Minimum Depth of Binary Tree | |
104 | Maximum Depth of Binary Tree | |
110 | Balanced Binary Tree | |
124 | Binary Tree Maximum Path Sum | |
250 | Count Univalue Subtrees | |
366 | Find Leaves of Binary Tree | |
337 | House Robber III |
BFS
题号 | 题目名称 | 状态 |
---|---|---|
107 | Binary Tree Level Order Traversal II | |
103 | Binary Tree Zigzag Level Order Traversal | |
199 | Binary Tree Right Side View |
BST
题号 | 题目名称 | 状态 |
---|---|---|
98 | Validate Binary Search Tree | |
235 | Lowest Common Ancestor of a Binary Search Tree | |
236 | Lowest Common Ancestor of a Binary Tree | |
108 | Convert Sorted Array to Binary Search Tree | |
109 | Convert Sorted List to Binary Search Tree | |
173 | Binary Search Tree Iterator | |
230 | Kth Smallest Element in a BST | |
297 | Serialize and Deserialize Binary Tree | |
285 | Inorder Successor in BST | |
270 | Closest Binary Search Tree Value | |
272 | Closest Binary Search Tree Value II | |
99 | Recover Binary Search Tree |
冷门
题号 | 题目名称 | 状态 |
---|---|---|
156 | Binary Tree Upside Down | |
114 | Flatten Binary Tree to Linked List | |
255 | Verify Preorder Sequence in Binary Search Tree | |
333 | Largest BST Subtree | |
222 | Count Complete Tree Nodes | |
105 | Construct Binary Tree from Preorder and Inorder Traversal | |
106 | Construct Binary Tree from Inorder and Postorder Traversal | |
116 | Populating Next Right Pointers in Each Node | |
117 | Populating Next Right Pointers in Each Node II | |
314 | Binary Tree Vertical Order Traversal | |
96 | Unique Binary Search Trees | |
95 | Unique Binary Search Trees II | |
331 | Verify Preorder Serialization of a Binary Tree |