从开始这个Github已经有将近两年时间, 很高兴这个repo可以帮到有需要的人. 我一直认为, 知识本身是无价的, 因此每逢闲暇, 我就会来维护这个repo, 给刷题的朋友们一些我的想法和见解. 下面来简单介绍一下这个repo:
README.md: 所有所做过的题目
ReviewPage.md: 所有题目的总结和归纳(不断完善中)
KnowledgeHash2.md: 对所做过的知识点的一些笔记
SystemDesign.md: 对系统设计的一些笔记
Future Milestone: 我准备将一些有意思的题目,做成视频的形式给大家参考
希望大家学习顺利, 对未来充满希望(程序员也是找到好老板的!) 有问题可以给我写邮件(wangdeve@gmail.com), 或者在GitHub上发issue给我.
Squence | Problem | Level | Language | Tags | Video Tutorial |
---|---|---|---|---|---|
0 | Binary Tree Zigzag Level Order Traversal.java | Medium | Java | [BFS, Stack, Tree] | |
1 | Count of Smaller Number before itself.java | Hard | Java | [] | |
2 | Count of Smaller Number.java | Review | Java | [Binary Search, Segment Tree] | |
3 | Delete Digits.java | Medium | Java | [] | |
4 | Find the Weak Connected Component in the Directed Graph.java | Medium | Java | [Union Find] | |
5 | Flatten 2D Vector.java | Medium | Java | [Design] | |
6 | Fraction to Recurring Decimal.java | Medium | Java | [Hash Table, Math] | |
7 | Gray Code.java | Medium | Java | [Backtracking] | |
8 | Group Shifted Strings.java | Easy | Java | [] | |
9 | Hamming Distance.java | Easy | Java | [] | |
10 | Happy Number.java | Easy | Java | [] | |
11 | HashHeap.java | Hard | Java | [] | |
12 | HashWithArray.java | Easy | Java | [] | |
13 | Heapify.java | Review | Java | [Heap] | |
14 | Heaters.java | Easy | Java | [] | |
15 | IndexMatch.java | Easy | Java | [] | |
16 | Inorder Successor in Binary Search Tree.java | Medium | Java | [BST, Tree] | |
17 | Insert Node in a Binary Search Tree .java | Easy | Java | [BST] | |
18 | Intersection of Two Arrays.java | Easy | Java | [] | |
19 | Intersection of Two Linked Lists.java | Easy | Java | [Linked List] | |
20 | Interval Sum II.java | Hard | Java | [] | |
21 | Isomorphic Strings.java | Easy | Java | [] | |
22 | Jewels and Stones.java | Easy | Java | [Hash Table] | |
23 | Kth Largest Element.java | Review | Java | [Divide and Conquer, Heap, Quick Sort] | |
24 | Kth Smallest Sum In Two Sorted Arrays.java | Hard | Java | [] | |
25 | LFU Cache.java | Hard | Java | [Design, Hash Table] | |
26 | Longest Univalue Path.java | Easy | Java | [] | |
27 | Majority Number II.java | Medium | Java | [Enumeration, Greedy] | |
28 | Majority Number III.java | Medium | Java | [Hash Table, Linked List] | |
29 | Matrix Zigzag Traversal.java | Easy | Java | [] | |
30 | Maximum Subarray III.java | Review | Java | [] | |
31 | Minimum Absolute Difference in BST.java | Easy | Java | [BST] | |
32 | Minimum Height Trees.java | Medium | Java | [BFS, Graph] | |
33 | Minimum Subarray.java | Easy | Java | [Array, Greedy] | |
34 | Missing Ranges.java | Medium | Java | [Array] | |
35 | Next Permutation.java | Medium | Java | [Array] | |
36 | O(1) Check Power of 2.java | Easy | Java | [Bit Manipulation] | |
37 | Palindrome Permutation II.java | Medium | Java | [Backtracking, Permutation] | |
38 | Partition Array by Odd and Even.java | Easy | Java | [Array, Two Pointers] | |
39 | Pascal's Triangle II.java | Easy | Java | [] | |
40 | Permutation Index.java | Easy | Java | [] | |
41 | Permutation Sequence.java | Medium | Java | [Backtracking, Math] | |
42 | Populating Next Right Pointers in Each Node II.java | Hard | Java | [] | |
43 | Product of Array Exclude Itself.java | Medium | Java | [Array] | |
44 | Recover Rotated Sorted Array.java | Easy | Java | [Array] | |
45 | Remove Duplicates from Unsorted List.java | Medium | Java | [Linked List] | |
46 | Remove Node in Binary Search Tree.java | Hard | Java | [BST] | |
47 | Reshape the Matrix.java | Easy | Java | [] | |
48 | Reverse String.java | Easy | Java | [] | |
49 | Roman to Integer.java | Easy | Java | [] | |
50 | Rotate Image.java | Medium | Java | [Array, Enumeration] | |
51 | Search Insert Position.java | Easy | Java | [] | |
52 | Search Rotated in Sorted Array II.java | Medium | Java | [Array, Binary Search] | |
53 | Search Rotated in Sorted Array.java | Hard | Java | [] | |
54 | Shortest Word Distance.java | Easy | Java | [] | |
55 | Single Number II.java | Medium | Java | [Bit Manipulation] | |
56 | Single Number III.java | Medium | Java | [Bit Manipulation] | |
57 | Single Number.java | Easy | Java | [] | |
58 | Sliding Window Maximum.java | Hard | Java | [] | |
59 | Space Replacement.java | Medium | Java | [String] | |
60 | Stone Game.java | Medium | Java | [DP] | |
61 | String Permutation.java | Easy | Java | [] | |
62 | String to Integer(atoi).java | Easy | Java | [] | |
63 | Strobogrammatic Number.java | Easy | Java | [] | |
64 | Subarray Sum II.java | Hard | Java | [Array, Binary Search, Two Pointers] | |
65 | The Smallest Difference.java | Medium | Java | [Array, Sort, Two Pointers] | |
66 | Total Occurrence of Target.java | Medium | Java | [] | |
67 | Trailing Zeros.java | Easy | Java | [Math] | |
68 | Two Lists Sum.java | Medium | Java | [Linked List] | |
69 | Two Strings Are Anagrams.java | Easy | Java | [] | |
70 | Ugly Number II.java | Medium | Java | [DP, Heap, Math] | |
71 | Valid Parentheses.java | Easy | Java | [] | |
72 | Valid Sudoku.java | Easy | Java | [] | |
73 | Word Ladder II.java | Hard | Java | [] | |
74 | Word Pattern.java | Easy | Java | [] | |
75 | Zigzag Iterator.java | Medium | Java | [BST] | |
76 | Find Anagram Mappings.java | Easy | Java | [Hash Table] | |
77 | Judge Route Circle.java | Easy | Java | [String] | |
78 | Island Perimeter.java | Easy | Java | [Hash Table] | |
79 | First Unique Character in a String.java | Easy | Java | [Hash Table, String] | |
80 | Power of Three.java | Easy | Java | [Math] | |
81 | Plus One.java | Easy | Java | [Array, Math] | |
82 | Power of Two.java | Easy | Java | [Bit Manipulation, Math] | |
83 | Reverse Vowels of a String.java | Easy | Java | [String, Two Pointers] | |
84 | Guess Number Higher or Lower.java | Easy | Java | [Binary Search] | |
85 | Encode and Decode TinyURL.java | Medium | Java | [Hash Table, Math] | |
86 | Wiggle Sort.java | Medium | Java | [Array, Sort] | |
87 | Queue Reconstruction by Height.java | Medium | Java | [Greedy] | |
88 | 2 Sum II - Input array is sorted.java | Medium | Java | [Array, Binary Search, Two Pointers] | |
89 | 2 Sum II.java | Medium | Java | [Array, Binary Search, Two Pointers] | |
90 | Coin Change.java | Medium | Java | [DP, Memoization, Sequence DP] | |
91 | Maximum Product Subarray.java | Medium | Java | [Array, DP] | |
92 | 3 Sum Closest.java | Medium | Java | [Array, Two Pointers] | |
93 | Triangle Count.java | Medium | Java | [Array] | |
94 | 3 Sum.java | Medium | Java | [Array, Two Pointers] | |
95 | 4 Sum.java | Medium | Java | [Hash Table] | |
96 | k Sum.java | Hard | Java | [DP] | |
97 | Longest Increasing Subsequence.java | Medium | Java | [Binary Search, Coordinate DP, DP, Memoization, Sequence DP] | |
98 | Unique Binary Search Tree.java | Medium | Java | [BST, DP, Tree] | |
99 | Trim a Binary Search Tree.java | Easy | Java | [BST, Tree] | |
100 | Unique Paths II.java | Medium | Java | [Array, Coordinate DP, DP] | |
101 | Bomb Enemy.java | Medium | Java | [Coordinate DP, DP] | |
102 | 3 Sum Smaller.java | Medium | Java | [Array, Two Pointers] | |
103 | Array Partition I.java | Easy | Java | [Array] | |
104 | 1-bit and 2-bit Characters.java | Easy | Java | [Array] | |
105 | Non-decreasing Array.java | Easy | Java | [Array] | |
106 | Max Consecutive Ones.java | Easy | Java | [Array] | |
107 | Find All Numbers Disappeared in an Array.java | Easy | Java | [Array] | |
108 | Maximum Average Subarray I.java | Easy | Java | [Array] | |
109 | Largest Number At Least Twice of Others.java | Easy | Java | [Array] | |
110 | Toeplitz Matrix.java | Easy | Java | [Array] | |
111 | Sum of Two Integers.java | Easy | Java | [Bit Manipulation] | |
112 | Swap Bits.java | Easy | Java | [Bit Manipulation] | |
113 | Update Bits.java | Medium | Java | [Bit Manipulation] | |
114 | Maximum XOR of Two Numbers in an Array.java | Medium | Java | [Bit Manipulation, Trie] | |
115 | Perfect Squares.java | Medium | Java | [BFS, DP, Math, Partition DP] | |
116 | Backpack VI.java | Medium | Java | [Backpack DP, DP] | |
117 | Copy Books.java | Hard | Java | [Binary Search, DP, Partition DP] | |
118 | Valid Perfect Square.java | Review | Java | [Binary Search, Math] | |
119 | Intersection of Two Arrays II.java | Easy | Java | [Binary Search, Hash Table, Sort, Two Pointers] | |
120 | Scramble String.java | Hard | Java | [DP, Interval DP, String] | |
121 | Binary Search Tree Iterator.java | Medium | Java | [BST, Design, Stack, Tree] | |
122 | Flatten Nested List Iterator.java | Medium | Java | [Design, Stack] | |
123 | Best Time to Buy and Sell Stock with Cooldown.java | Medium | Java | [DP] | |
124 | Find Peak Element.java | Medium | Java | [Array, Binary Search] | |
125 | Longest Common Subsequence.java | Medium | Java | [DP, Double Sequence DP] | |
126 | Interleaving String.java | Hard | Java | [DP, String] | |
127 | Letter Combinations of a Phone Number.java | Medium | Java | [Backtracking, String] | |
128 | Edit Distance.java | Hard | Java | [DP, Double Sequence DP, String] | |
129 | Distinct Subsequences.java | Hard | Java | [DP, String] | |
130 | Regular Expression Matching.java | Review | Java | [Backtracking, DP, String] | |
131 | Majority Element.java | Easy | Java | [Array, Bit Manipulation, Divide and Conquer] | |
132 | Wildcard Matching.java | Hard | Java | [Backtracking, DP, Greedy, String] | |
133 | Ones and Zeroes.java | Hard | Java | [DP] | |
134 | Pow(x,n).java | Medium | Java | [Binary Search, Math] | |
135 | Word Break II.java | Hard | Java | [Backtracking, DFS, DP, Memoization] | |
136 | Nested List Weight Sum.java | Easy | Java | [BFS, DFS] | |
137 | Same Tree.java | Easy | Java | [DFS, Tree] | |
138 | Convert Sorted Array to Binary Search Tree.java | Easy | Java | [DFS, Divide and Conquer, Tree] | |
139 | Construct Binary Tree from Inorder and Preorder Traversal.java | Medium | Java | [Array, DFS, Divide and Conquer, Hash Table, Tree] | |
140 | Add Binary.java | Easy | Java | [Math, String] | |
141 | Add Digits.java | Easy | Java | [Math] | |
142 | Add Two Numbers.java | Medium | Java | [Linked List, Math] | |
143 | Add Two Numbers II.java | Medium | Java | [Linked List] | |
144 | Balanced Binary Tree.java | Medium | Java | [DFS, Tree] | |
145 | Valid Anagram.java | Easy | Java | [Hash Table, Sort] | |
146 | Populating Next Right Pointers in Each Node.java | Medium | Java | [DFS, Divide and Conquer, Tree] | |
147 | Validate Binary Search Tree.java | Medium | Java | [BST, DFS, Divide and Conquer, Tree] | |
148 | Convert Sorted List to Binary Search Tree.java | Medium | Java | [BST, DFS, Divide and Conquer, Linked List] | |
149 | Flatten Binary Tree to Linked List.java | Medium | Java | [Binary Tree, DFS] | |
150 | Binary Tree Paths.java | Easy | Java | [Backtracking, Binary Tree, DFS] | |
151 | Minimum Size Subarray Sum.java | Medium | Java | [Array, Binary Search, Two Pointers] | |
152 | Clone Graph.java | Medium | Java | [BFS, DFS, Graph] | |
153 | Longest Substring Without Repeating Characters.java | Medium | Java | [Hash Table, String, Two Pointers] | |
154 | Minimum Window Substring.java | Hard | Java | [Hash Table, String, Two Pointers] | |
155 | Linked List Cycle.java | Easy | Java | [Linked List, Two Pointers] | |
156 | Remove Nth Node From End of List.java | Medium | Java | [Linked List, Two Pointers] | |
157 | Longest Substring with At Most K Distinct Characters.java | Medium | Java | [Hash Table, String] | |
158 | Linked List Cycle II.java | Medium | Java | [Linked List, Math, Two Pointers] | |
159 | Kth Smallest Number in Sorted Matrix.java | Medium | Java | [Binary Search, Heap] | |
160 | Find Minimum in Rotated Sorted Array.java | Medium | Java | [Array, Binary Search] | |
161 | Find Minimum in Rotated Sorted Array II.java | Hard | Java | [Array, Binary Search] | |
162 | Connecting Graph.java | Medium | Java | [Union Find] | |
163 | Connecting Graph II.java | Medium | Java | [Union Find] | |
164 | Connecting Graph III.java | Medium | Java | [Union Find] | |
165 | Number of Islands.java | Medium | Java | [BFS, DFS, Matrix DFS, Union Find] | |
166 | Number of Islands II.java | Hard | Java | [Union Find] | |
167 | Surrounded Regions.java | Medium | Java | [BFS, DFS, Matrix DFS, Union Find] | |
168 | Implement Trie.java | Medium | Java | [Design, Trie] | |
169 | Add and Search Word.java | Medium | Java | [Backtracking, Design, Trie] | |
170 | Word Search II.java | Hard | Java | [Backtracking, DFS, Trie] | |
171 | Word Search.java | Medium | Java | [Array, Backtracking, DFS] | |
172 | Word Squares.java | Hard | Java | [Backtracking, Trie] | |
173 | Trapping Rain Water.java | Hard | Java | [Array, Stack, Two Pointers] | |
174 | Trapping Rain Water II.java | Hard | Java | [BFS, Heap] | |
175 | Data Stream Median.java | Hard | Java | [Design, Heap] | |
176 | Sliding Window Median.java | Hard | Java | [Design, Heap] | |
177 | Min Stack.java | Easy | Java | [Design, Stack] | |
178 | Implement Queue using Stacks.java | Easy | Java | [Design, Stack] | |
179 | Decode String.java | Medium | Java | [DFS, Divide and Conquer, Stack] | |
180 | Largest Rectangle in Histogram.java | Hard | Java | [Array, Monotonous Stack, Stack] | |
181 | Maximum Binary Tree.java | Medium | Java | [Stack, Tree] | |
182 | Reverse Integer.java | Easy | Java | [Math] | |
183 | Swap Nodes in Pairs.java | Medium | Java | [Linked List] | |
184 | Find Peak Element II.java | Hard | Java | [Binary Search, DFS, Divide and Conquer] | |
185 | Sqrt(x).java | Easy | Java | [Binary Search, Math] | |
186 | First Bad Version.java | Easy | Java | [Binary Search] | |
187 | Wood Cut.java | Medium | Java | [Binary Search] | |
188 | Find the Duplicate Number.java | Medium | Java | [Array, Binary Search, Two Pointers] | |
189 | Palindrome Pairs.java | Hard | Java | [Hash Table, String, Trie] | |
190 | Game of Life.java | Medium | Java | [Array] | |
191 | Maximum Average Subarray II.java | Review | Java | [Array, Binary Search, PreSum] | |
192 | Meeting Rooms.java | Easy | Java | [PriorityQueue, Sort, Sweep Line] | |
193 | Number of Airplane in the sky.java | Medium | Java | [Array, Interval, PriorityQueue, Sort, Sweep Line] | |
194 | Meeting Rooms II.java | Medium | Java | [Greedy, Heap, Sort, Sweep Line] | |
195 | Building Outline.java | Review | Java | [Binary Indexed Tree, Divide and Conquer, Heap, Segment Tree, Sweep Line] | |
196 | Unique Path.java | Medium | Java | [Array, Coordinate DP, DP] | |
197 | Maximal Rectangle.java | Hard | Java | [Array, DP, Hash Table, Stack] | |
198 | Maximal Square.java | Medium | Java | [Coordinate DP, DP] | |
199 | Longest Increasing Path in a Matrix.java | Hard | Java | [Coordinate DP, DFS, DP, Memoization, Topological Sort] | |
200 | Coins in a Line.java | Medium | Java | [DP, Game Theory, Greedy] | |
201 | Coins in a Line II.java | Medium | Java | [Array, DP, Game Theory, Memoization, MiniMax] | |
202 | Binary Tree Inorder Traversal.java | Easy | Java | [Hash Table, Stack, Tree] | |
203 | Binary Tree Postorder Traversal.java | Medium | Java | [Stack, Tree, Two Stacks] | |
204 | Change to Anagram.java | Easy | Java | [String] | |
205 | Classical Binary Search.java | Easy | Java | [Binary Search] | |
206 | Climbing Stairs.java | Easy | Java | [DP, Memoization, Sequence DP] | |
207 | Coins in a Line III.java | Hard | Java | [Array, DP, Game Theory, Interval DP, Memoization] | |
208 | Closest Binary Search Tree Value.java | Easy | Java | [BST, Binary Search, Tree] | |
209 | Compare Version Numbers.java | Medium | Java | [String] | |
210 | Count Complete Tree Nodes.java | Medium | Java | [Binary Search, Tree] | |
211 | Course Schedule.java | Medium | Java | [BFS, Backtracking, DFS, Graph, Topological Sort] | |
212 | Course Schedule II.java | Medium | Java | [BFS, DFS, Graph, Topological Sort] | |
213 | Binary Tree Preorder Traversal.java | Easy | Java | [BFS, DFS, Stack, Tree] | |
214 | Closest Number in Sorted Array.java | Easy | Java | [Binary Search] | |
215 | Complete Binary Tree.java | Easy | Java | [BFS, Tree] | |
216 | Compare Strings.java | Easy | Java | [String] | |
217 | Contains Duplicate.java | Easy | Java | [Array, Hash Table] | |
218 | Contains Duplicate II.java | Easy | Java | [Array, Hash Table] | |
219 | Contains Duplicate III.java | Medium | Java | [BST] | |
220 | Burst Balloons.java | Hard | Java | [DP, Divide and Conquer, Interval DP, Memoization] | |
221 | Nim Game.java | Easy | Java | [Brainteaser, DP, Game Theory] | |
222 | Convert Integer A to Integer B.java | Easy | Java | [Bit Manipulation] | |
223 | Cosine Similarity.java | Easy | Java | [Basic Implementation] | |
224 | Count 1 in Binary.java | Easy | Java | [Bit Manipulation] | |
225 | Count and Say.java | Easy | Java | [Basic Implementation, String] | |
226 | One Edit Distance.java | Medium | Java | [String] | |
227 | K Edit Distance.java | Hard | Java | [DP, Double Sequence DP, Trie] | |
228 | Jump Game.java | Medium | Java | [Array, DP, Greedy] | |
229 | Coin Change 2.java | Medium | Java | [Backpack DP, DP, Sequence DP] | |
230 | Paint House.java | Easy | Java | [DP, Sequence DP] | |
231 | Decode Ways.java | Medium | Java | [DP, Partition DP, String] | |
232 | Longest Continuous Increasing Subsequence.java | Easy | Java | [Array, Coordinate DP, DP] | |
233 | Minimum Path Sum.java | Medium | Java | [Array, Coordinate DP, DP] | |
234 | Counting Bits.java | Medium | Java | [Bit Manipulation, Bitwise DP, DP] | |
235 | Continuous Subarray Sum.java | Medium | Java | [Coordinate DP, DP, Math] | |
236 | House Robber.java | Easy | Java | [DP, Sequence DP] | |
237 | House Robber II.java | Medium | Java | [DP, Sequence DP] | |
238 | House Robber III.java | Medium | Java | [DFS, DP, Status DP, Tree] | |
239 | Paint House II.java | Hard | Java | [DP, Sequence DP] | |
240 | Best Time to Buy and Sell Stock I.java | Easy | Java | [Array, DP, Sequence DP] | |
241 | Best Time to Buy and Sell Stock II.java | Easy | Java | [Array, DP, Greedy, Sequence DP] | |
242 | Best Time to Buy and Sell Stock III .java | Hard | Java | [Array, DP, Sequence DP] | |
243 | Best Time to Buy and Sell Stock IV.java | Hard | Java | [DP, Sequence DP] | |
244 | Russian Doll Envelopes.java | Hard | Java | [Binary Search, Coordinate DP, DP] | |
245 | Permutation in String.java | Medium | Java | [Two Pointers] | |
246 | Permutations II.java | Medium | Java | [Backtracking] | |
247 | Shuffle an Array.java | Medium | Java | [Permutation] | |
248 | Find All Anagrams in a String.java | Easy | Java | [Hash Table] | |
249 | Group Anagrams.java | Medium | Java | [Hash Table, String] | |
250 | Backpack.java | Medium | Java | [Backpack DP, DP] | |
251 | Backpack II.java | Medium | Java | [Backpack DP, DP] | |
252 | Backpack V.java | Medium | Java | [Backpack DP, DP] | |
253 | Count Primes.java | Easy | Java | [Hash Table, Math] | |
254 | Delete Node in a Linked List.java | Easy | Java | [Linked List] | |
255 | Excel Sheet Column Number.java | Easy | Java | [Math] | |
256 | Excel Sheet Column Title.java | Easy | Java | [Math] | |
257 | Flip Game.java | Easy | Java | [String] | |
258 | Expression Tree Build.java | Hard | Java | [Binary Tree, Expression Tree, Minimum Binary Tree, Stack] | |
259 | Expression Evaluation.java | Hard | Java | [Binary Tree, DFS, Expression Tree, Minimum Binary Tree, Stack] | |
260 | Convert Expression to Polish Notation.java | Hard | Java | [Binary Tree, DFS, Expression Tree, Stack] | |
261 | Convert Expression to Reverse Polish Notation.java | Hard | Java | [Binary Tree, DFS, Expression Tree, Stack] | |
262 | Evaluate Reverse Polish Notation.java | Medium | Java | [Stack] | |
263 | Decode Ways II.java | Hard | Java | [DP, Partition DP] | |
264 | Palindrome Partitioning II.java | Hard | Java | [DP, Partition DP] | |
265 | Backpack III.java | Hard | Java | [Backpack DP, DP] | |
266 | First Missing Positive.java | Hard | Java | [Array] | |
267 | Implement strStr().java | Easy | Java | [String, Two Pointers] | |
268 | Insertion Sort List.java | Medium | Java | [Linked List, Sort] | |
269 | Integer to English Words.java | Hard | Java | [Math, String] | |
270 | Interleaving Positive and Negative Numbers.java | Medium | Java | [Two Pointers] | |
271 | Largest Number.java | Medium | Java | [Sort] | |
272 | Last Position of Target.java | Easy | Java | [Binary Search] | |
273 | Length of Last Word.java | Easy | Java | [String] | |
274 | Longest Common Substring.java | Medium | Java | [DP, Double Sequence DP, String] | |
275 | Longest Increasing Continuous subsequence.java | Easy | Java | [Array, Coordinate DP, DP] | |
276 | Longest Increasing Continuous subsequence II.java | Medium | Java | [Array, Coordinate DP, DP, Memoization] | |
277 | N-Queens.java | Hard | Java | [Backtracking] | |
278 | N-Queens II.java | Hard | Java | [Backtracking] | |
279 | Maximum Subarray.java | Easy | Java | [Array, DFS, DP, Divide and Conquer, PreSum, Sequence DP] | |
280 | Maximum Subarray II.java | Medium | Java | [Array, DP, Greedy, PreSum, Sequence DP] | |
281 | Median.java | Easy | Java | [Array, Quick Select, Quick Sort] | |
282 | Merge Sorted Array.java | Easy | Java | [Array, Two Pointers] | |
283 | Middle of Linked List.java | Easy | Java | [Linked List] | |
284 | Singleton.java | Easy | Java | [Design] | |
285 | Remove Linked List Elements.java | Easy | Java | [Linked List] | |
286 | Fibonacci.java | Easy | Java | [DP, Math, Memoization] | |
287 | Palindrome Linked List.java | Easy | Java | [Linked List, Two Pointers] | |
288 | Reverse Linked List.java | Easy | Java | [Linked List] | |
289 | Reverse Linked List II .java | Medium | Java | [Linked List] | |
290 | Palindrome Permutation.java | Easy | Java | [Hash Table] | |
291 | Valid Palindrome.java | Easy | Java | [String, Two Pointers] | |
292 | Implement Stack using Queues.java | Easy | Java | [Design, Stack] | |
293 | Implement Stack.java | Easy | Java | [Stack] | |
294 | Invert Binary Tree.java | Easy | Java | [BFS, DFS, Tree] | |
295 | Maximum Depth of Binary Tree.java | Easy | Java | [DFS, Tree] | |
296 | Minimum Depth of Binary Tree.java | Easy | Java | [BFS, DFS, Tree] | |
297 | Symmetric Tree.java | Easy | Java | [BFS, DFS, Tree] | |
298 | Tweaked Identical Binary Tree.java | Easy | Java | [DFS, Tree] | |
299 | Merge Two Binary Trees.java | Easy | Java | [DFS, Tree] | |
300 | Subtree.java | Easy | Java | [DFS, Tree] | |
301 | Lowest Common Ancestor of a Binary Tree.java | Medium | Java | [DFS, Tree] | |
302 | Lowest Common Ancestor II.java | Easy | Java | [Hash Table, Tree] | |
303 | Lowest Common Ancestor of a Binary Search Tree.java | Medium | Java | [BST, DFS, Tree] | |
304 | Hash Function.java | Easy | Java | [Hash Table] | |
305 | Merge Two Sorted Lists.java | Easy | Java | [Linked List] | |
306 | Missing Number.java | Easy | Java | [Array, Bit Manipulation, Math] | |
307 | LRU Cache.java | Hard | Java | [Design, Hash Table, Linked List] | |
308 | Remove Duplicates from Sorted Array.java | Easy | Java | [Array, Two Pointers] | |
309 | Remove Duplicates from Sorted Array II.java | Medium | Java | [Array, Two Pointers] | |
310 | Remove Duplicates from Sorted List.java | Easy | Java | [Linked List] | |
311 | Remove Duplicates from Sorted List II.java | Medium | Java | [Linked List] | |
312 | QuickSort.java | Medium | Java | [Sort] | |
313 | MergeSort.java | Medium | Java | [Merge Sort, Sort] | |
314 | Longest Word in Dictionary.java | Easy | Java | [Hash Table, Trie] | |
315 | Binary Tree Level Order Traversal.java | Medium | Java | [BFS, DFS, Tree] | |
316 | Binary Tree Level Order Traversal II.java | Medium | Java | [BFS, Tree] | |
317 | Binary Tree Longest Consecutive Sequence II.java | Medium | Java | [DFS, Divide and Conquer, Double Recursive, Tree] | |
318 | Binary Tree Maximum Path Sum.java | Hard | Java | [DFS, DP, Tree, Tree DP] | |
319 | Path Sum.java | Easy | Java | [DFS, Tree] | |
320 | Path Sum II.java | Easy | Java | [Backtracking, DFS, Tree] | |
321 | Path Sum III.java | Easy | Java | [DFS, Double Recursive, Tree] | |
322 | Rotate String.java | Easy | Java | [String] | |
323 | Combinations.java | Medium | Java | [Backtracking, Combination, DFS] | |
324 | Combination Sum.java | Medium | Java | [Array, Backtracking, Combination, DFS] | |
325 | Combination Sum II.java | Medium | Java | [Array, Backtracking, Combination, DFS] | |
326 | Combination Sum III.java | Medium | Java | [Array, Backtracking, Combination, DFS] | |
327 | Combination Sum IV.java | Medium | Java | [Array, Backpack DP, DP] | |
328 | Subset.java | Medium | Java | [Array, BFS, Backtracking, Bit Manipulation, DFS] | |
329 | Subsets II.java | Medium | Java | [Array, BFS, Backtracking, DFS] | |
330 | Binary Tree Right Side View.java | Medium | Java | [BFS, DFS, Tree] | |
331 | Binary Tree Maximum Path Sum II.java | Medium | Java | [DFS, Tree] | |
332 | Rotate List.java | Medium | Java | [Linked List, Two Pointers] | |
333 | Basic Calculator.java | Hard | Java | [Binary Tree, Expression Tree, Math, Minimum Binary Tree, Stack] | |
334 | Longest Consecutive Sequence.java | Hard | Java | [Array, Hash Table, Union Find] | |
335 | Binary Tree Longest Consecutive Sequence.java | Medium | Java | [DFS, Divide and Conquer, Tree] | |
336 | Number of Connected Components in an Undirected Graph.java | Medium | Java | [BFS, DFS, Graph, Union Find] | |
337 | Next Closest Time.java | Medium | Java | [Basic Implementation, Enumeration, String] | |
338 | Serilization and Deserialization Of Binary Tree.java | Hard | Java | [BFS, DFS, Design, Divide and Conquer, Tree] | |
339 | Partition Array.java | Medium | Java | [Array, Quick Sort, Sort, Two Pointers] | |
340 | Word Ladder.java | Medium | Java | [BFS] | |
341 | Word Break.java | Medium | Java | [DP, Sequence DP] | |
342 | Unique Word Abbreviation.java | Medium | Java | [Design, Hash Table] | |
343 | Unique Binary Search Tree II.java | Medium | Java | [BST, DP, Divide and Conquer, Tree] | |
344 | Ugly Number.java | Medium | Java | [Math] | |
345 | Top K Frequent Words.java | Medium | Java | [Hash Table, Heap, PriorityQueue, Trie] | |
346 | Segment Tree Build.java | Medium | Java | [Binary Tree, Divide and Conquer, Segment Tree] | |
347 | Segment Tree Build II.java | Medium | Java | [Binary Tree, Divide and Conquer, Segment Tree] | |
348 | Segment Tree Query.java | Medium | Java | [Binary Tree, DFS, Divide and Conquer, Segment Tree] | |
349 | Segment Tree Modify.java | Medium | Java | [Binary Tree, DFS, Divide and Conquer, Segment Tree] | |
350 | Segment Tree Query II.java | Medium | Java | [Binary Tree, DFS, Divide and Conquer, Segment Tree] | |
351 | Count of Smaller Numbers After Self.java | Review | Java | [BST, Binary Indexed Tree, Binary Search, Divide and Conquer, Segment Tree] | |
352 | ColorGrid.java | Medium | Java | [Design, Hash Table] | |
353 | Container With Most Water.java | Medium | Java | [Array, Two Pointers] | |
354 | Convert Binary Search Tree to Doubly Linked List.java | Medium | Java | [Linked List, Tree] | |
355 | Copy List with Random Pointer.java | Medium | Java | [Hash Table, Linked List] | |
356 | Encode and Decode Strings.java | Medium | Java | [String] | |
357 | Fast Power.java | Medium | Java | [DFS, Divide and Conquer] | |
358 | Find the Connected Component in the Undirected Graph.java | Medium | Java | [BFS, DFS] | |
359 | HashWithCustomizedClass(LinkedList).java | Medium | Java | [Hash Table] | |
360 | Interval Minimum Number.java | Medium | Java | [Binary Search, Divide and Conquer, Segment Tree] | |
361 | Interval Sum.java | Medium | Java | [Binary Search, Segment Tree] | |
362 | Kth Smallest Element in a BST.java | Medium | Java | [BST, DFS, Stack, Tree] | |
363 | Longest Common Prefix.java | Easy | Java | [String] | |
364 | Majority Element II.java | Medium | Java | [Array] | |
365 | Merge k Sorted Lists.java | Medium | Java | [Divide and Conquer, Heap, Linked List, PriorityQueue] | |
366 | Merge k Sorted Arrays.java | Medium | Java | [Heap, PriorityQueue] | |
367 | Permutations.java | Medium | Java | [Backtracking, DFS, Permutation] | |
368 | Partition List.java | Medium | Java | [Linked List, Two Pointers] | |
369 | Peeking Iterator.java | Medium | Java | [Design] | |
370 | Rehashing.java | Medium | Java | [Hash Table] | |
371 | Reorder List.java | Medium | Java | [Linked List] | |
372 | Restore IP Addresses.java | Medium | Java | [Backtracking, DFS, String] | |
373 | Reverse Words in a String.java | Medium | Java | [String] | |
374 | Reverse Words in a String II.java | Medium | Java | [String] | |
375 | Reverse Words in a String III.java | Easy | Java | [String] | |
376 | Search a 2D Matrix.java | Medium | Java | [Array, Binary Search] | |
377 | Search a 2D Matrix II.java | Medium | Java | [Binary Search, Divide and Conquer] | |
378 | Search for a Range.java | Medium | Java | [Array, Binary Search] | |
379 | Search Range in Binary Search Tree .java | Medium | Java | [BST, Binary Tree] | |
380 | Merge Sorted Array II.java | Easy | Java | [Array] | |
381 | Nth to Last Node in List.java | Easy | Java | [Linked List] | |
382 | Sort List.java | Medium | Java | [Divide and Conquer, Linked List, Merge Sort, Sort] | |
383 | Summary Ranges.java | Medium | Java | [Array] | |
384 | Top K Frequent Elements.java | Medium | Java | [Hash Table, Heap, PriorityQueue] | |
385 | Topological Sorting.java | Medium | Java | [BFS, DFS, Topological Sort] | |
386 | Median of two Sorted Arrays.java | Hard | Java | [Array, Binary Search, DFS, Divide and Conquer] | |
387 | Remove Duplicate Letters.java | Hard | Java | [Greedy, Hash Table, Stack] | |
388 | Spiral Matrix.java | Medium | Java | [Array, Enumeration] | |
389 | Expression Add Operators.java | Hard | Java | [Backtracking, DFS, Divide and Conquer, String] | |
390 | Insert Interval.java | Hard | Java | [Array, PriorityQueue, Sort] | |
391 | Shortest Palindrome.java | Hard | Java | [KMP, String] | |
392 | 2 Sum.java | Easy | Java | [Array, Hash Table] | |
393 | K Empty Slots.java | Hard | Java | [Array, BST, TreeSet] | |
394 | Count of Range Sum.java | Hard | Java | [BST, Divide and Conquer, Merge Sort, PreSum] | |
395 | Max Sum of Rectangle No Larger Than K.java | Hard | Java | [Array, BST, Binary Search, DP, Queue, TreeSet] | |
396 | Perfect Rectangle.java | Hard | Java | [Design, Geometry, Hash Table] | |
397 | Construct Binary Tree from Inorder and Postorder Traversal.java | Medium | Java | [Array, DFS, Divide and Conquer, Tree] | |
398 | Generate Parentheses.java | Medium | Java | [Backtracking, DFS, Sequence DFS, String] | |
399 | Strobogrammatic Number II.java | Medium | Java | [DFS, Math, Sequence DFS] | |
400 | Alien Dictionary.java | Hard | Java | [BFS, Backtracking, DFS, Graph, Topological Sort] | |
401 | Flip Game II.java | Medium | Java | [DFS, DP, backtracking] | |
402 | Max Area of Island.java | Easy | Java | [Array, DFS] | |
403 | Max Points on a Line.java | Hard | Java | [Array, Geometry, Hash Table, Math] | |
404 | Number of Digit One.java | Hard | Java | [Math] | |
405 | Binary Representation.java | Hard | Java | [Bit Manipulation, String] | |
406 | Palindrome Partitioning.java | Medium | Java | [Backtracking, DFS] | |
407 | Graph Valid Tree.java | Medium | Java | [BFS, DFS, Graph, Union Find] | |
408 | Recover Binary Search Tree.java | Hard | Java | [BST, DFS, Tree] | |
409 | Subarray Sum.java | Easy | Java | [Array, Hash Table] | |
410 | Submatrix Sum.java | Medium | Java | [Array, Hash Table, PreSum] | |
411 | Longest Palindromic Substring.java | Medium | Java | [DP, String] | |
412 | Longest Palindromic Subsequence.java | Medium | Java | [DFS, DP, Interval DP, Memoization] | |
413 | Jump Game II.java | Hard | Java | [Array, Coordinate DP, DP, Greedy] | |
414 | Gas Station.java | Medium | Java | [Greedy] | |
415 | Triangles.java | Medium | Java | [Array, Coordinate DP, DFS, DP, Memoization] | |
416 | Range Sum Query - Immutable.java | Easy | Java | [DP, PreSum] | |
417 | Longest Valid Parentheses.java | Hard | Java | [Coordinate DP, Stack, String] | |
418 | Remove Invalid Parentheses.java | Review | Java | [BFS, DFS, DP] | |
419 | Paint Fence.java | Easy | Java | [DP, Sequence DP] | |
420 | Merge Intervals.java | Medium | Java | [Array, PriorityQueue, Sort, Sweep Line] | |
421 | H-Index.java | Medium | Java | [Bucket Sort, Hash Table, Sort] | |
422 | H-Index II.java | Medium | Java | [Binary Search] | |
423 | Sort Color.java | Medium | Java | [Array, Partition, Sort, Two Pointers] | |
424 | Sort Colors II.java | Medium | Java | [Partition, Sort, Two Pointers] | |
425 | Sort Letters by Case.java | Medium | Java | [Partition, Sort, String, Two Pointers] | |
426 | Subarray Sum Closest.java | Medium | Java | [PreSum, Sort] | |
427 | Task Scheduler.java | Medium | Java | [Array, Enumeration, Greedy, PriorityQueue, Queue] | |
428 | Rearrange String k Distance Apart.java | Hard | Java | [Greedy, Hash Table, Heap] | |
429 | Exam Room.java | Medium | Java | [PriorityQueue, Sort] | |
430 | Anagrams.java | Medium | Java | [Array, Hash Table] | |
431 | Path Sum IV.java | Medium | Java | [DFS, Hash Table, Tree] | |
432 | Longest Words.java | Easy | Java | [Hash Table, String] | |
433 | Unique Characters.java | Easy | Java | [Array, String] | |
434 | Number Of Corner Rectangles.java | Medium | Java | [DP, Math] | |
435 | Palindromic Substrings.java | Medium | Java | [DP, String] | |
436 | Multiply Strings.java | Medium | Java | [Math, String] |