Skip to content

Y103249314/LintCode

 
 

Repository files navigation

Java Algorithm Problems

程序员的一天

从开始这个Github已经有将近两年时间, 很高兴这个repo可以帮到有需要的人. 我一直认为, 知识本身是无价的, 因此每逢闲暇, 我就会来维护这个repo, 给刷题的朋友们一些我的想法和见解. 下面来简单介绍一下这个repo:

README.md: 所有所做过的题目

ReviewPage.md: 所有题目的总结和归纳(不断完善中)

KnowledgeHash2.md: 对所做过的知识点的一些笔记

SystemDesign.md: 对系统设计的一些笔记

Future Milestone: 我准备将一些有意思的题目,做成视频的形式给大家参考

借此机会, 正式介绍一下自己, 以及我背后的大老板

介绍一下自己!

希望大家学习顺利, 对未来充满希望(程序员也是找到好老板的!) 有问题可以给我写邮件([email protected]), 或者在GitHub上发issue给我.

Squence Problem Level Language Video Tutorial
0 2 Sum II - Input array is sorted.java Medium Java
1 2 Sum II.java Medium Java
2 2 Sum.java Medium Java Link
3 3 Sum Closest.java Medium Java
4 3 Sum Smaller.java Java
5 3 Sum.java Medium Java
6 4 Sum.java Medium Java
7 A B.java Easy Java
8 Add and Search Word.java Medium Java
9 Add Binary.java Easy Java
10 Add Digits.java Easy Java
11 Add Two Numbers II.java Medium Java
12 Add Two Numbers.java Easy Java
13 Alien Dictionary.java Hard Java
14 Anagrams.java Medium Java
15 Array Partition I.java Easy Java
16 Backpack II.java Medium Java
17 Backpack.java Medium Java
18 Balanced Binary Tree.java Medium Java
19 Best Time to Buy and Sell Stock I.java Easy Java
20 Best Time to Buy and Sell Stock II.java Easy Java
21 Best Time to Buy and Sell Stock III .java Medium Java
22 Best Time to Buy and Sell Stock IV.java Hard Java
23 Binary Representation.java Hard Java
24 Binary Search Tree Iterator.java Hard Java
25 Binary Tree Inorder Traversal.java Easy Java
26 Binary Tree Level Order Traversal II.java Medium Java
27 Binary Tree Level Order Traversal.java Medium Java
28 Binary Tree Longest Consecutive Sequence.java Medium Java
29 Binary Tree Maximum Path Sum II.java Medium Java
30 Binary Tree Maximum Path Sum.java Medium Java
31 Binary Tree Path Sum.java Easy Java
32 Binary Tree Paths.java Easy Java
33 Binary Tree Postorder Traversal.java Easy Java
34 Binary Tree Preorder Traversal.java Easy Java
35 Binary Tree Right Side View.java Medium Java
36 Binary Tree Serialization.java Medium Java
37 Binary Tree Zigzag Level Order Traversal.java Medium Java
38 Building Outline.java Hard Java
39 Burst Balloons.java Java
40 Change to Anagram.java Easy Java
41 Classical Binary Search.java Easy Java
42 Climbing Stairs.java Easy Java
43 Clone Graph.java Medium Java
44 Closest Binary Search Tree Value.java Easy Java
45 Closest Number in Sorted Array.java Easy Java
46 Coins in a Line.java Java
47 ColorGrid.java Medium Java
48 Combination Sum II.java Medium Java
49 Combination Sum.java Medium Java
50 Combinations.java Medium Java
51 Compare Strings.java Easy Java
52 Complete Binary Tree.java Easy Java
53 Construct Binary Tree from Inorder and Postorder Traversal.java Medium Java
54 Construct Binary Tree from Inorder and Preorder Traversal.java Medium Java
55 Container With Most Water.java Java
56 Contains Duplicate II.java Easy Java
57 Contains Duplicate III.java Medium Java
58 Contains Duplicate.java Easy Java
59 Convert Binary Search Tree to Doubly Linked List.java Medium Java
60 Convert Expression to Polish Notation.java Hard Java
61 Convert Expression to Reverse Polish Notation.java Hard Java
62 Convert Integer A to Integer B.java Easy Java
63 Convert Sorted Array to Binary Search Tree With Minimal Height.java Easy Java
64 Convert Sorted List to Binary Search Tree.java Medium Java
65 Copy List with Random Pointer.java Medium Java
66 Cosine Similarity.java Easy Java
67 Count 1 in Binary.java Easy Java
68 Count and Say.java Easy Java
69 Count of Smaller Number before itself.java Hard Java
70 Count of Smaller Number.java Medium Java
71 Count Primes.java Easy Java
72 Course Schedule II.java Medium Java
73 Course Schedule.java Medium Java
74 Data Stream Median.java Hard Java
75 Delete Digits.java Medium Java
76 Delete Node in the Middle of Singly Linked List.java Easy Java
77 Distinct Subsequences.java Hard Java
78 Edit Distance.java Medium Java
79 Encode and Decode Strings.java Medium Java
80 ExcelSheetColumnNumber .java Easy Java
81 Expression Evaluation.java Hard Java
82 Expression Tree Build.java Hard Java
83 Fast Power.java Medium Java
84 Fibonacci.java Easy Java
85 Find All Numbers Disappeared in an Array.java Easy Java
86 Find Minimum in Rotated Sorted Array II.java Java
87 Find Minimum in Rotated Sorted Array.java Java
88 Find Peak Element II.java Java
89 Find Peak Element.java Java
90 Find the Connected Component in the Undirected Graph.java Medium Java
91 Find the Weak Connected Component in the Directed Graph.java Medium Java
92 First Bad Version.java Medium Java
93 First Missing Positive.java Java
94 Flatten 2D Vector.java Java
95 Flatten Binary Tree to Linked List.java Easy Java
96 Flattern 2D Vector.java Java
97 Flip Game II.java Java
98 Flip Game.java Java
99 Fraction to Recurring Decimal.java Java
100 Game of Life.java Java
101 Gas Station.java Java
102 Generate Parentheses.java Medium Java
103 Graph Valid Tree.java Medium Java
104 Gray Code.java Medium Java
105 Group Anagrams.java Medium Java
106 Group Shifted Strings.java Easy Java
107 H-Index II.java Java
108 H-Index.java Java
109 Hamming Distance.java Easy Java
110 Happy Number.java Easy Java
111 Hash Function.java Easy Java
112 HashHeap.java Hard Java
113 HashWithArray.java Easy Java
114 HashWithCustomizedClass(LinkedList).java Medium Java
115 Heapify.java Medium Java
116 Heaters.java Easy Java
117 House Robber II.java Medium Java
118 House Robber III.java Hard Java
119 House Robber.java Easy Java
120 Identical Binary Tree.java Easy Java
121 Implement Queue by Two Stacks.java Java
122 Implement Queue using Stacks.java Easy Java
123 Implement Stack by Two Queues.java Java
124 Implement Stack using Queues.java Easy Java
125 Implement Stack.java Java
126 Implement strStr().java Java
127 Implement Trie (Prefix Tree).java Java
128 Implement Trie.java Medium Java
129 IndexMatch.java Easy Java
130 Inorder Successor in Binary Search Tree.java Medium Java
131 Insert Interval.java Easy Java
132 Insert Node in a Binary Search Tree .java Easy Java
133 Insertion Sort List.java Java
134 Integer to English Words.java Java
135 Interleaving Positive and Negative Numbers.java Java
136 Interleaving String.java Java
137 Intersection of Two Arrays.java Easy Java
138 Intersection of Two Linked Lists.java Easy Java
139 Interval Minimum Number.java Medium Java
140 Interval Sum II.java Hard Java
141 Interval Sum.java Medium Java
142 Invert Binary Tree.java Easy Java
143 Isomorphic Strings.java Easy Java
144 Jump Game II.java Hard Java
145 Jump Game.java Medium Java
146 Kth Largest Element.java Medium Java
147 Kth Smallest Element in a BST.java Java
148 Kth Smallest Number in Sorted Matrix.java Medium Java
149 Kth Smallest Sum In Two Sorted Arrays.java Hard Java
150 Largest Number.java Java
151 Largest Rectangle in Histogram.java Java
152 Last Position of Target.java Java
153 Length of Last Word.java Java
154 Letter Combinations of a Phone Number.java Medium Java
155 Linked List Cycle II.java Java
156 Linked List Cycle.java Java
157 Longest Common Prefix.java Medium Java
158 Longest Common Subsequence.java Java
159 Longest Common Substring.java Java
160 Longest Consecutive Sequence.java Java
161 Longest Increasing Continuous subsequence II.java Java
162 Longest Increasing Continuous subsequence.java Java
163 Longest Increasing Subsequence.java Java
164 Longest Palindromic Substring.java Medium Java
165 Longest Substring with At Most K Distinct Characters.java Medium Java
166 Longest Substring Without Repeating Characters.java Medium Java
167 Longest Univalue Path.java Easy Java
168 Longest Words.java Java
169 Lowest Common Ancestor II.java Easy Java
170 Lowest Common Ancestor of a Binary Search Tree.java Medium Java
171 Lowest Common Ancestor.java Easy Java
172 LRU Cache.java Hard Java
173 Majority Number II.java Medium Java
174 Majority Number III.java Medium Java
175 Majority Number.java Easy Java
176 Matrix Zigzag Traversal.java Easy Java
177 Max Area of Island.java Easy Java
178 Max Consecutive Ones.java Easy Java
179 Max Tree.java Hard Java
180 Maximal Square.java Medium Java
181 Maximum Depth of Binary Tree.java Easy Java
182 Maximum Product Subarray.java Java
183 Maximum Subarray III.java Java
184 Maximum Subarray.java Java
185 Maximum SubarrayII.java Java
186 MaximumSubarray.java Java
187 MaximumSubarrayII.java Java
188 Median of two Sorted Arrays.java Hard Java
189 Median.java Java
190 Meeting Rooms II.java Medium Java
191 Meeting Rooms.java Easy Java
192 Merge Intervals.java Easy Java
193 Merge k Sorted Arrays.java Medium Java
194 Merge k Sorted Lists.java Medium Java
195 Merge Sorted Array II.java Java
196 Merge Sorted Array.java Easy Java
197 Merge Two Binary Trees.java Easy Java
198 Merge Two Sorted List.java Easy Java
199 Merge Two Sorted Lists.java Easy Java
200 Middle of Linked List.java Java
201 Min Stack.java Easy Java
202 Minimum Absolute Difference in BST.java Easy Java
203 Minimum Height Trees.java Java
204 Minimum Path Sum.java Java
205 Minimum Size Subarray Sum.java Medium Java
206 Minimum Subarray.java Java
207 Minimum Window Substring.java Hard Java
208 MinimumDepthOfBinaryTree.java Easy Java
209 Missing Ranges.java Java
210 Multiply Strings.java Medium Java
211 Next Permutation.java Medium Java
212 Nim Game.java Java
213 NQueens.java Java
214 NQueensII.java Java
215 Nth to Last Node in List.java Java
216 Number of Airplane in the sky.java Medium Java
217 Number of Islands II.java Hard Java
218 Number of Islands.java Medium Java
219 Number Triangles.java Java
220 O(1) Check Power of 2.java Java
221 One Edit Distance.java Medium Java
222 Paint Fence.java Java
223 Palindrome Linked List.java Java
224 Palindrome Partitioning II.java Java
225 Palindrome Partitioning.java Java
226 Palindrome Permutation II.java Medium Java
227 Palindrome Permutation.java Easy Java
228 Partition Array by Odd and Even.java Java
229 Partition Array.java Java
230 Partition List.java Java
231 Pascal's Triangle II.java Easy Java
232 Peeking Iterator.java Java
233 Perfect Squares.java Java
234 Permutation Index.java Easy Java
235 Permutation Sequence.java Medium Java
236 Permutations II.java Medium Java
237 Permutations.java Medium Java
238 Plus One.java Java
239 Populating Next Right Pointers in Each Node II.java Hard Java
240 Populating Next Right Pointers in Each Node.java Medium Java
241 Pow(x,n).java Java
242 Power of Three.java Easy Java
243 Product of Array Exclude Itself.java Java
244 QuickSort.java Easy Java
245 Recover Rotated Sorted Array.java Java
246 Rehashing.java Medium Java
247 Remove Duplicates from Sorted Array.java Easy Java
248 Remove Duplicates from Sorted List II.java Java
249 Remove Duplicates from Sorted List.java Easy Java
250 Remove Duplicates from Unsorted List.java Java
251 Remove Linked List Elements.java Java
252 Remove Node in Binary Search Tree.java Hard Java
253 Remove Nth Node From End of List.java Java
254 Reorder List.java Java
255 Reshape the Matrix.java Easy Java
256 Restore IP Addresses.java Java
257 Reverse Integer.java Easy Java
258 Reverse Linked List II .java Java
259 Reverse Linked List.java Easy Java
260 Reverse String.java Easy Java
261 Reverse Words in a String II.java Medium Java
262 Reverse Words in a String.java Medium Java
263 reverseInteger.java Java
264 Roman to Integer.java Easy Java
265 Rotate Image.java Medium Java
266 Rotate List.java Java
267 Rotate String.java Java
268 Search a 2D Matrix II.java Java
269 Search a 2D Matrix.java Java
270 Search for a Range.java Java
271 Search Insert Position.java Java
272 Search Range in Binary Search Tree .java Medium Java
273 Search Rotated in Sorted Array II.java Java
274 Search Rotated in Sorted Array.java Hard Java
275 Segment Tree Build II.java Medium Java
276 Segment Tree Build.java Medium Java
277 Segment Tree Modify.java Medium Java
278 Segment Tree Query II.java Medium Java
279 Segment Tree Query.java Medium Java
280 Serilization and Deserialization Of Binary Tree.java Java
281 Shortest Word Distance.java Easy Java
282 Single Number II.java Java
283 Single Number III.java Java
284 Single Number.java Easy Java
285 Singleton.java Java
286 Sliding Window Maximum.java Java
287 Sliding Window Median.java Java
288 Sort Color.java Java
289 Sort Colors II.java Java
290 Sort Letters by Case.java Java
291 Sort List.java Java
292 Space Replacement.java Java
293 Sqrt(x).java Easy Java
294 Stone Game.java Java
295 String Permutation.java Easy Java
296 String to Integer(atoi).java Easy Java
297 Strobogrammatic Number II.java Medium Java
298 Strobogrammatic Number.java Easy Java
299 StrStr.java Java
300 Subarray Sum Closest.java Medium Java
301 Subarray Sum.java Easy Java
302 Subset.java Medium Java
303 Subsets II.java Medium Java
304 Subtree.java Easy Java
305 Summary Ranges.java Java
306 Surrounded Regions.java Java
307 Swap Nodes in Pairs.java Java
308 Symmetric Binary Tree.java Easy Java
309 The Smallest Difference.java Java
310 Top K Frequent Elements.java Medium Java
311 Top K Frequent Words.java Medium Java
312 Topological Sorting.java Medium Java
313 Total Occurrence of Target.java Java
314 Trailing Zeros.java Java
315 Trapping Rain Water II.java Hard Java
316 Trapping Rain Water.java Medium Java
317 Triangle Count.java Java
318 Tweaked Identical Binary Tree.java Easy Java
319 Two Lists Sum.java Java
320 Two Strings Are Anagrams.java Easy Java
321 Ugly Number II.java Java
322 Ugly Number.java Medium Java
323 Unique Binary Search Tree II.java Java
324 Unique Binary Search Tree.java Java
325 Unique Characters.java Java
326 Unique Path.java Medium Java
327 Unique Paths II.java Java
328 Unique Word Abbreviation.java Java
329 Update Bits.java Java
330 Valid Anagram.java Easy Java
331 Valid Palindrome.java Easy Java Link
332 Valid Parentheses.java Easy Java
333 Valid Sudoku.java Easy Java
334 Validate Binary Search Tree.java Medium Java
335 Wiggle Sort.java Java
336 Wood Cut.java Java
337 Word Break II.java Hard Java
338 Word Break.java Medium Java
339 Word Ladder II.java Hard Java
340 Word Ladder.java Medium Java
341 Word Pattern.java Easy Java
342 Word Search II.java Hard Java
343 Word Search.java Medium Java
344 Zigzag Iterator.java Java

About

Java Solutions to problems on LintCode/LeetCode

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Java 100.0%