Java solutions of Leetcode
# | Title | Solution | Difficulty |
---|---|---|---|
21 | Merge Two Sorted Lists | code/note | Easy |
24 | Swap Nodes in Pairs | code/note | Medium |
50 | Pow(x, n) | code/note | Medium |
70 | Climbing Stairs | code/note | Easy |
95 | Unique Binary Search Trees II | code/note | Medium |
104 | Maximum Depth of Binary Tree | code/note | Easy |
206 | Reverse Linked List | code/note | Easy |
509 | Fibonacci Number | code/note | Easy |
779 | K-th Symbol in Grammar | code/note | Medium |
# | Title | Solution | Difficulty |
---|---|---|---|
7 | Reverse Integer | code/note | Easy |
9 | Palindrome Number | code/note | Easy |
171 | Excel Sheet Column Number | code/note | Easy |
172 | Factorial Trailing Zeroes | code/note | Easy |
204 | Count Primes | code/note | Easy |
258 | Add Digits | code/note | Easy |
263 | Ugly Number | code/note | Easy |
278 | Count Primes | code/note | Easy |
292 | Nim Game | code/note | Easy |
292 | Nim Game | code/note | Easy |
326 | Power of Three | code/note | Easy |
342 | Power of Four | code/note | Easy |
441 | Arranging Coins | code/note | Easy |
453 | Minimum Moves to Equal Array Elements | code/note | Easy |
458 | Poor Pigs | code/note | Hard |
463 | Island Perimeter | code/note | Easy |
492 | Construct the Rectangle | code/note | Easy |
504 | Base 7 | code/note | Easy |
507 | Perfect Number | code/note | Easy |
633 | Sum of Square Numbers | code/note | Easy |
728 | Self Dividing Numbers | code/note | Easy |
1025 | Divisor Game | code/note | Easy |
# | Title | Solution | Difficulty |
---|---|---|---|
190 | Reverse Bits | code/note | Easy |
191 | Number of 1 Bits | code/note | Easy |
231 | Power of Two | code/note | Easy |
268 | Missing Number | code/note | Easy |
338 | Counting Bits | code/note | Medium |
371 | Sum of Two Integers | code/note | Medium |
401 | Binary Watch | code/note | Easy |
405 | Convert a Number to Hexadecimal | code/note | Easy |
476 | Number Complement | code/note | Easy |
461 | Hamming Distance | code/note | Easy |
693 | Binary Number with Alternating Bits | code/note | Easy |
# | Title | Solution | Difficulty |
---|---|---|---|
53 | Maximum Subarray | code/note | Easy |
64 | Minimum Path Sum | code/note | Medium |
139 | Word Break | code/note | Medium |
198 | House Robber | code/note | Easy |
213 | House Robber II | code/note | Medium |
279 | Perfect Squares | code/note | Medium |
300 | Longest Increasing Subsequence | code/note | Medium |
746 | Min Cost Climbing Stairs | code/note | Easy |
1027 | Longest Arithmetic Sequence | code/note | Medium |
# | Title | Solution | Difficulty |
---|---|---|---|
20 | Valid Parentheses | code/note | Easy |
71 | Simplify Path | code/note | Medium |
155 | Min Stack | code/note | Easy |
225 | Implement Stack using Queues | code/note | Easy |
232 | Implement Queue using Stacks | code/note | Easy |
682 | Baseball Game | code/note | Easy |
# | Title | Solution | Difficulty |
---|---|---|---|
83 | Remove Duplicates from Sorted List | code/note | Easy |
141 | Linked List Cycle | code/note | Easy |
160 | Intersection of Two Linked Lists | code/note | Easy |
203 | Remove Linked List Elements | code/note | Easy |
234 | Palindrome Linked List | code/note | Easy |
237 | Delete Node in a Linked List | code/note | Easy |
# | Title | Solution | Difficulty |
---|---|---|---|
17 | Letter Combinations of a Phone Number | code/note | Medium |
93 | Restore IP Addresses | code/note | Medium |
# | Title | Solution | Difficulty |
---|---|---|---|
175 | Combine Two Tables | code | Easy |
176 | Second Highest Salary | code | Easy |
# | Title | Solution | Difficulty |
---|---|---|---|
1202 | Smallest String With Swaps | code/note | Medium |
# | Title | Solution | Difficulty |
---|---|---|---|
455 | Assign Cookies | code/note | Easy |
680 | Valid Palindrome II | code/note | Easy |
754 | Reach a Number | code/note | Easy |