Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/gouthampradhan/leetcode

Leetcode solutions
https://github.com/gouthampradhan/leetcode

algorithms coding-interviews competitive-programming java leetcode leetcode-java leetcode-solutions

Last synced: 6 days ago
JSON representation

Leetcode solutions

Awesome Lists containing this project

README

        

# Leetcode solutions in Java

My accepted leetcode solutions to some of the common interview problems.
Also, some solutions have youtube video link.

#### [Array](src/main/java/array)

- [Pascals Traiangle II](src/main/java/array/PascalsTriangle.java) (Easy)
- [Product Of Array Except Self](src/main/java/array/ProductOfArrayExceptSelf.java) (Medium)
- [Rotate Matrix](src/main/java/array/RotateMatrix.java) (Medium)
- [Set Matrix Zeroes](src/main/java/array/SetMatrixZeroes.java) (Medium)
- [Third Maximum Number](src/main/java/array/ThirdMaximumNumber.java) (Easy)
- [Two Sum](src/main/java/array/TwoSum.java) (Easy)
- [TwoSum II](src/main/java/array/TwoSumII.java) (Easy)
- [Can Place Flowers](src/main/java/array/CanPlaceFlowers.java) (Easy)
- [Merge Intervals](src/main/java/array/MergeIntervals.java) (Medium)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [First Missing Positive](src/main/java/array/FirstMissingPositive.java) (Hard)
- [Fruit Into Baskets](src/main/java/array/FruitIntoBaskets.java) (Medium)
- [MaxProduct Of Three Numbers](src/main/java/array/MaxProductOfThreeNumbers.java) (Easy)
- [Missing Number](src/main/java/array/MissingNumber.java) (Easy)
- [Merge Sorted Array](src/main/java/array/MergeSortedArray.java) (Easy)
- [Rotate Array](src/main/java/array/RotateArray.java) (Easy)
- [Sort Colors](src/main/java/array/SortColors.java) (Medium)
- [Battleships in a Board](src/main/java/array/BattleshipsInABoard.java) (Medium)
- [Find the Celebrity](src/main/java/array/FindTheCelebrity.java) (Medium)
- [Meeting Rooms](src/main/java/array/MeetingRooms.java) (Easy)
- [Longest Continuous Increasing Subsequence](src/main/java/array/LongestIncreasingSubsequence.java) (Easy)
- [Sparse Matrix Multiplication](src/main/java/array/SparseMatrixMultiplication.java) (Medium)
- [Read N Characters Given Read4](src/main/java/array/ReadNCharacters.java) (Easy)
- [Maximum Swap](src/main/java/array/MaximumSwap.java) (Medium)
- [H-Index](src/main/java/array/HIndex.java) (Medium)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Insert Interval](src/main/java/array/InsertInterval.java) (Hard)
- [Increasing Triplet Subsequence](src/main/java/array/IncreasingTripletSubsequence.java) (Medium)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [K Empty Slots](src/main/java/array/KEmptySlots.java) (Hard)
- [Subarray Sum Equals K](src/main/java/array/SubarraySumEqualsK.java) (Medium)
- [Pour Water](src/main/java/array/PourWater.java) (Medium)
- [Relative Ranks](src/main/java/array/RelativeRanks.java) (Easy)
- [Next Greater Element I](src/main/java/array/NextGreaterElementI.java) (Easy)
- [Largest Number At Least Twice of Others](src/main/java/array/LargestNumberAtLeastTwice.java) (Easy)
- [Minimum Moves to Equal Array Elements II](src/main/java/array/MinimumMovesToEqualArray.java) (Median)
- [Image Smoother](src/main/java/array/ImageSmoother.java) (Easy)
- [Minimum Index Sum of Two Lists](src/main/java/array/MinimumIndexSumOfTwoLists.java) (Easy)
- [Card Flipping Game](src/main/java/array/CardFilipGame.java) (Medium)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Employee Free Time](src/main/java/array/EmployeeFreeTime.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Best Meeting Point](src/main/java/array/BestMeetingPoint.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [My Calendar III](src/main/java/array/MyCalendarThree.java) (Hard)
- [Champagne Tower](src/main/java/array/ChampagneTower.java) (Medium)
- [Valid Tic-Tac-Toe State](src/main/java/array/ValidTicTacToeState.java) (Medium)
- [Number of Subarrays with Bounded Maximum](src/main/java/array/SubArraysWithBoundedMaximum.java) (Medium)
- [Surface Area of 3D Shapes](src/main/java/array/SurfaceAreaOfThreeDShapes.java) (Easy)
- [Max Consecutive Ones](src/main/java/array/MaxConsecutiveOnes.java) (Easy)
- [Max Consecutive Ones II](src/main/java/array/MaxConsecutiveOnesII.java) (Medium)
- [Add to Array-Form of Integer](src/main/java/array/AddToArrayFormOfInteger.java) (Easy)
- [Find Pivot Index](src/main/java/array/FindPivotIndex.java) (Easy)
- [Largest Time for Given Digits](src/main/java/array/LargestTimeForGivenDigits.java) (Easy)
- [Minimum Time Difference](src/main/java/array/MinimumTimeDifference.java) (Medium)
- [Reveal Cards In Increasing Order](src/main/java/array/RevealCardsInIncreasingOrder.java) (Medium)
- [Sort Array By Parity II](src/main/java/array/SortArrayByParityII.java) (Easy)
- [Matrix Cells in Distance Order](src/main/java/array/MatrixCellsinDistanceOrder.java) (Easy)
- [Maximum Sum of Two Non-Overlapping Subarrays](src/main/java/array/MaximumSumofTwoNonOverlappingSubarrays.java) (Medium)
- [Longest Line of Consecutive One in Matrix](src/main/java/array/LongestLineofConsecutiveOneinMatrix.java) (Medium)
- [Array Partition I](src/main/java/array/ArrayPartitionI.java) (Easy)
- [Relative Sort Array](src/main/java/array/RelativeSortArray.java) (Easy)
- [Meeting Scheduler](src/main/java/array/MeetingScheduler.java) (Medium)
- [Minimum Swaps to Group All 1's Together](src/main/java/array/MinimumSwapsToGroupAll1Together.java) (Medium)
- [Array Nesting](src/main/java/array/ArrayNesting.java) (Medium)

#### [Backtracking](src/main/java/backtracking)

- [Combinations](src/main/java/backtracking/Combinations.java) (Medium)
- [Combinations Sum](src/main/java/backtracking/CombinationSum.java) (Medium)
- [Combinations Sum II](src/main/java/backtracking/CombinationSumII.java) (Medium)
- [Letter Phone Number](src/main/java/backtracking/LetterPhoneNumber.java) (Medium)
- [Paliandrome Partitioning](src/main/java/backtracking/PalindromePartitioning.java) (Medium)
- [Permutations](src/main/java/backtracking/Permutations.java) (Medium)
- [Permutations II](src/main/java/backtracking/PermutationsII.java) (Medium)
- [SubSets](src/main/java/backtracking/Subsets.java) (Medium)
- [SubSet II](src/main/java/backtracking/SubsetsII.java) (Medium)
- [Word Search](src/main/java/backtracking/WordSearch.java) (Medium)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Word Search II](src/main/java/backtracking/WordSearchII.java) (Hard)
- [Generate Parentheses](src/main/java/backtracking/GenerateParentheses.java) (Medium)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Remove Invalid Parentheses](src/main/java/backtracking/RemoveInvalidParentheses.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Regular Expression Matching](src/main/java/backtracking/RegularExpressionMatching.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Expression Add Operators](src/main/java/backtracking/ExpressionAddOperators.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Wildcard Matching](src/main/java/backtracking/WildcardMatching.java) (Hard)
- [Letter Case Permutation](src/main/java/backtracking/LetterCasePermutation.java) (Easy)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Zuma Game](src/main/java/backtracking/ZumaGame.java) (Hard)
- [Matchsticks to Square](src/main/java/backtracking/MatchsticksToSquare.java) (Medium)

#### [Binary Search](src/main/java/binary_search)

- [Minimum Sorted Rotated Array](src/main/java/binary_search/MinSortedRotatedArray.java) (Medium)
- [Search in a Rotated Sorted Array](src/main/java/binary_search/SearchRotatedSortedArray.java) (Medium)
- [Search for a Range](src/main/java/binary_search/SearchForARange.java) (Medium)
- [Sqrt(x)](src/main/java/binary_search/SqrtX.java) (Easy)
- [Search Insert Position](src/main/java/binary_search/SearchInsertPosition.java) (Easy)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Median of Two Sorted Arrays](src/main/java/binary_search/MedianOfTwoSortedArrays.java) (Hard)
- [Pow(x, n)](src/main/java/binary_search/PowXN.java) (Medium)
- [Find Peak Element](src/main/java/binary_search/FindPeakElement.java) (Medium)
- [Target Sum](src/main/java/binary_search/TargetSum.java) (Medium)
- [H-Index II](src/main/java/binary_search/HIndexII.java) (Medium)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Swim in Rising Water](src/main/java/binary_search/SwimInRisingWater.java) (Hard)
- [Time Based Key-Value Store](src/main/java/binary_search/TimeBasedKeyValuePair.java) (Medium)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Minimum Window Subsequence](src/main/java/binary_search/MinimumWindowSubsequence.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Koko Eating Bananas](src/main/java/binary_search/KokoEatingBananas.java) (Hard)
- [Single Element in a Sorted Array](src/main/java/binary_search/SingleElementInASortedArray.java) (Medium)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Minimize the Maximum Adjacent Element Difference](src/main/java/binary_search/MinimizeTheMaximumAdjacentElementDifference.java) (Hard)
- [Youtube video explanation](https://www.youtube.com/watch?v=2fCtjA_eitU)

#### [Bit Manipulation](src/main/java/bit_manipulation)

- [Gray Code](src/main/java/bit_manipulation/GrayCode.java) (Medium)
- [Hamming Distance](src/main/java/bit_manipulation/HammingDistance.java) (Easy)
- [Total Hamming Distance](src/main/java/bit_manipulation/TotalHammingDistance.java) (Medium)
- [Divide Two Integers](src/main/java/bit_manipulation/DivideTwoIntegers.java) (Medium)
- [Binary Number with Alternating Bits](src/main/java/bit_manipulation/BinaryNumberWithAlternatingBits.java) (Easy)
- [Binary Watch](src/main/java/bit_manipulation/BinaryWatch.java) (Easy)

#### [Breadth First Search](src/main/java/breadth_first_search)

- [Binaray Tree Level Order Traversal](src/main/java/breadth_first_search/BinarayTreeLevelOrderTraversal.java) (Medium)
- [Word Ladder](src/main/java/breadth_first_search/WordLadder.java) (Medium)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Word Ladder II](src/main/java/breadth_first_search/WordLadderII.java) (Hard)
- [Walls and Gates](src/main/java/breadth_first_search/WallsAndGates.java) (Medium)
- [Open the lock](src/main/java/breadth_first_search/OpenTheLock.java) (Medium)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Cut Off Trees for Golf Event](src/main/java/breadth_first_search/CutOffTreesForGolfEvent.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Race Car](src/main/java/breadth_first_search/RaceCar.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Bus Routes](src/main/java/breadth_first_search/BusRoutes.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Sliding Puzzle](src/main/java/breadth_first_search/SlidingPuzzle.java) (Hard)
- [Matrix](src/main/java/breadth_first_search/Matrix.java) (Medium)
- [Rotting Oranges](src/main/java/breadth_first_search/RottingOranges.java) (Medium)

#### [Depth First Search](src/main/java/depth_first_search)

- [Minesweeper](src/main/java/depth_first_search/Minesweeper.java) (Medium)
- [Movie Recommend](src/main/java/depth_first_search/MovieRecommend.java) (Medium)
- [Number Of Islands](src/main/java/depth_first_search/NumberOfIslands.java) (Medium)
- [Course Schedule](src/main/java/depth_first_search/CourseSchedule.java) (Medium)
- [Course Schedule II](src/main/java/depth_first_search/CourseScheduleII.java) (Medium)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Alien Dictionary](src/main/java/depth_first_search/AlienDictionary.java) (Hard)
- [Graph Valid Tree](src/main/java/depth_first_search/GraphValidTree.java) (Medium)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Longest Consecutive Sequence](src/main/java/depth_first_search/LongestConsecutiveSequence.java) (Hard)
- [Accounts Merge](src/main/java/depth_first_search/AccountsMerge.java) (Medium)
- [CloneGraph](src/main/java/depth_first_search/CloneGraph.java) (Medium)
- [Island Perimeter](src/main/java/depth_first_search/IslandPerimeter.java) (Easy)
- [Number of Distinct Islands](src/main/java/depth_first_search/NumberOfDistinctIslands.java) (Medium)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Number of Distinct Islands II](src/main/java/depth_first_search/NumberOfDistinctIslandsII.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Smallest Rectangle Enclosing Black Pixels](src/main/java/depth_first_search/SmallestRectangleEnclosingBlackPixels.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Bricks Falling When Hit](src/main/java/depth_first_search/BricksFallingWhenHit.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Robot Room Cleaner](src/main/java/depth_first_search/RobotRoomCleaner.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Cracking the Safe](src/main/java/depth_first_search/CrackingTheSafe.java) (Hard)
- [All Paths From Source to Target](src/main/java/depth_first_search/AllPathsFromSourceToTarget.java) (Medium)
- [Max Area of Island](src/main/java/depth_first_search/MaxAreaOfIsland.java) (Medium)
- [Satisfiability of Equality Equations](src/main/java/depth_first_search/SatisfiabilityOfEquations.java) (Medium)
- [Number of Enclaves](src/main/java/depth_first_search/NumberOfEnclaves.java) (Medium)
- [As Far from Land as Possible](src/main/java/depth_first_search/AsFarfromLandAsPossible.java) (Medium)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Minimize Malware Spread](src/main/java/depth_first_search/MinimizeMalwareSpread.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Parallel Courses](src/main/java/depth_first_search/ParallelCourses.java) (Hard)
- [Connecting Cities With Minimum Cost](src/main/java/depth_first_search/ConnectingCitiesWithMinimumCost.java) (Medium)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Critical Connections in a Network](src/main/java/depth_first_search/CriticalConnection.java) (Hard)

#### [Design](src/main/java/design)

- [Copy List With Random Pointer](src/main/java/design/CopyListWithRandomPointer.java) (Medium)
- [Encode and Decode Tiny URL](src/main/java/design/EncodeAndDecodeTinyURL.java) (Medium)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [LFU Cache](src/main/java/design/LFUCache.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [LRU Cache](src/main/java/design/LRUCache.java) (Hard)
- [Insert Delete Get Random](src/main/java/design/RandomizedSet.java) (Medium)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Serialize Deserialize Binary Tree](src/main/java/design/SerializeDeserializeBinaryTree.java) (Hard)
- [Design Twitter](src/main/java/design/Twitter.java) (Medium)
- [Tic-Tac-Toe](src/main/java/design/TicTacToe.java) (Medium)
- [Implement Trie (Prefix Tree)](src/main/java/design/Trie.java) (Medium)
- [Binary Search Tree Iterator](src/main/java/design/BSTIterator.java) (Medium)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Design Search Autocomplete System](src/main/java/design/AutocompleteSystem.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Design Excel Sum Formula](src/main/java/design/Excel.java) (Hard)
- [Flatten Nested List Iterator](src/main/java/design/NestedIterator.java) (Medium)
- [Add and Search Word - Data structure design](src/main/java/design/WordDictionary.java) (Medium)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Prefix and Suffix Search](src/main/java/design/WordFilter.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Insert Delete GetRandom O(1) - Duplicates allowed](src/main/java/design/RandomizedCollection.java) (Hard)

#### [Divide and Conquer](src/main/java/divide_and_conquer)

- [Kth Largest Element In a Array](src/main/java/divide_and_conquer/KthLargestElementInAnArray.java) (Medium)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Reverse Pairs](src/main/java/divide_and_conquer/ReversePairs.java) (Hard)
- [Search in a 2D Matrix](src/main/java/divide_and_conquer/SearchA2DMatrix.java) (Medium)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [24 Game](src/main/java/divide_and_conquer/TwentyFourGame.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Reverse Pairs II](src/main/java/divide_and_conquer/ReversePairsII.java) (Hard)
- [My Calendar II](src/main/java/divide_and_conquer/MyCalendarII.java) (Medium)

#### [Dynamic Programming](src/main/java/dynamic_programming)

- [Best Time To Buy and Sell Stocks](src/main/java/dynamic_programming/BestTimeToBuyAndSellStocks.java) (Easy)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Best Time to Buy and Sell Stock III](src/main/java/dynamic_programming/BestTimeToBuyAndSellStockIII.java) (Hard)
- [Best Time to Buy and Sell Stock with Transaction Fee](src/main/java/dynamic_programming/BestTimeToBuyAndSellStocksWithFee.java) (Medium)
- [Climbing Stairs](src/main/java/dynamic_programming/ClimbingStairs.java) (Easy)
- [Coin Change](src/main/java/dynamic_programming/CoinChange.java) (Medium)
- [Coin Change 2](src/main/java/dynamic_programming/CoinChange2.java) (Medium)
- [Decode Ways](src/main/java/dynamic_programming/DecodeWays.java) (Medium)
- [House Robber](src/main/java/dynamic_programming/HouseRobber.java) (Easy)
- [House Robber II](src/main/java/dynamic_programming/HouseRobberII.java) (Medium)
- [Longest Increasing Subsequence](src/main/java/dynamic_programming/LongestIncreasingSubsequence.java) (Medium)
- [Longest Paliandromic Substring](src/main/java/dynamic_programming/LongestPaliandromicSubstring.java) (Medium)
- [Longest Palindromic Subsequence](src/main/java/dynamic_programming/LongestPalindromicSubsequence.java) (Medium)
- [Maximum Product Subarray](src/main/java/dynamic_programming/MaximumProductSubarray.java) (Medium)
- [Min Cost Climbing Stairs](src/main/java/dynamic_programming/MinCostClimbingStairs.java) (Easy)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Palindrome Partitioning II](src/main/java/dynamic_programming/PalindromePartitioningII.java) (Hard)
- [UniqueBinary Search Trees](src/main/java/dynamic_programming/UniqueBinarySearchTrees.java) (Medium)
- [Unique Binary Search Trees II](src/main/java/dynamic_programming/UniqueBinarySearchTreesII.java) (Medium)
- [WordBreak](src/main/java/dynamic_programming/WordBreak.java) (Medium)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [WordBreak II](src/main/java/dynamic_programming/WordBreakII.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Concatenated Words](src/main/java/dynamic_programming/ConcatenatedWords.java) (Hard)
- [Can I Win](src/main/java/dynamic_programming/CanIWin.java) (Medium)
- [Maximum Subarray](src/main/java/dynamic_programming/MaximumSubarray.java) (Easy)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Dungeon Game](src/main/java/dynamic_programming/DungeonGame.java) (Hard)
- [2 Keys Keyboard](src/main/java/dynamic_programming/TwoKeysKeyboard.java) (Medium)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Maximum Sum of 3 Non-Overlapping Subarrays](src/main/java/dynamic_programming/MaxSum3SubArray.java) (Hard)
- [Maximal Square](src/main/java/dynamic_programming/MaximalSquare.java) (Medium)
- [Continuous Subarray Sum](src/main/java/dynamic_programming/ContinuousSubarraySum.java) (Medium)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Decode Ways II](src/main/java/dynamic_programming/DecodeWaysII.java) (Hard)
- [Palindromic Substrings](src/main/java/dynamic_programming/PalindromicSubstrings.java) (Medium)
- [Number of Longest Increasing Subsequence](src/main/java/dynamic_programming/NumberOfLIS.java) (Medium)
- [Combination Sum IV](src/main/java/dynamic_programming/CombinationSumIV.java) (Medium)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Paint House II](src/main/java/dynamic_programming/PaintHouseII.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Split Array Largest Sum](src/main/java/dynamic_programming/SplitArrayLargestSum.java) (Hard)
- [Number Of Corner Rectangles](src/main/java/dynamic_programming/CornerRectangles.java) (Medium)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Burst Balloons](src/main/java/dynamic_programming/BurstBalloons.java) (Hard)
- [Largest Plus Sign](src/main/java/dynamic_programming/LargestPlusSign.java) (Medium)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Palindrome Pairs](src/main/java/dynamic_programming/PalindromePairs.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Cherry Pickup](src/main/java/dynamic_programming/CherryPickup.java) (Hard)
- [Knight Probability in Chessboard](src/main/java/dynamic_programming/KnightProbabilityInChessboard.java) (Medium)
- [Largest Sum of Averages](src/main/java/dynamic_programming/LargestSumOfAverages.java) (Medium)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Minimum Number of Refueling Stops](src/main/java/dynamic_programming/MinimumNumberOfRefuelingStops.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Cat and Mouse](src/main/java/dynamic_programming/CatAndMouse.java) (Hard)
- [Stone Game](src/main/java/dynamic_programming/StoneGame.java) (Medium)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Odd Even Jump](src/main/java/dynamic_programming/OddEvenJump.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Profitable Schemes](src/main/java/dynamic_programming/ProfitableSchemes.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Maximum Vacation Days](src/main/java/dynamic_programming/MaximumVacationDays.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Russian Doll Envelopes](src/main/java/dynamic_programming/RussianDollEnvelopes.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Student Attendance Record II](src/main/java/dynamic_programming/StudentAttendanceRecordII.java) (Hard)
- [Out of Boundary Paths](src/main/java/dynamic_programming/OutOfBoundaryPaths.java) (Medium)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Remove Boxes](src/main/java/dynamic_programming/RemoveBoxes.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Stickers to Spell Word](src/main/java/dynamic_programming/StickersToSpellWord.java) (Hard)
- [Ones and Zeroes](src/main/java/dynamic_programming/OnesAndZeroes.java) (Medium)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Encode String with Shortest Length](src/main/java/dynamic_programming/EncodeStringWithShortestLength.java) (Hard)
- [Length of Longest Fibonacci Subsequence](src/main/java/dynamic_programming/LengthofLongestFibonacciSubsequence.java) (Medium)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Make Array Strictly Increasing](src/main/java/dynamic_programming/MakeArrayStrictlyIncreasing.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Minimum Number of Taps to Open to Water a Garden](src/main/java/dynamic_programming/MinimumNumberOfTaps.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Delete Columns to Make Sorted III](src/main/java/dynamic_programming/DeleteColumnsToMakeSortedIII.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Handshakes That Don't Cross](src/main/java/dynamic_programming/HandshakesThatDontCross.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Minimum Difficulty of a Job Schedule](src/main/java/dynamic_programming/MinimumDifficultyOfAJobSchedule.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Jump Game V](src/main/java/dynamic_programming/JumpGameV.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Freedom Trail](src/main/java/dynamic_programming/FreedomTrail.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Strange Printer](src/main/java/dynamic_programming/StrangePrinter.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Minimum Cost to Merge Stones](src/main/java/dynamic_programming/MinimumCostToMergeStones.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Interleaving String](src/main/java/dynamic_programming/InterleavingString.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Count Vowels Permutation](src/main/java/dynamic_programming/CountVowelsPermutation.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Non-negative Integers without Consecutive Ones](src/main/java/dynamic_programming/NonNegativeIntegersWithoutConsecutiveOnes.java) (Hard)
- [Bomb Enemy](src/main/java/dynamic_programming/BombEnemy.java) (Medium)
- [Number of Dice Rolls With Target Sum](src/main/java/dynamic_programming/NumberOfDiceRollsWithTargetSum.java) (Medium)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Distinct Subsequences](src/main/java/dynamic_programming/DistinctSubsequences.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Distinct Subsequences II](src/main/java/dynamic_programming/DistinctSubsequencesII.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Minimum Distance to Type a Word Using Two Fingers](src/main/java/dynamic_programming/MinimumDistanceToTypeAWordUsingTwoFingers.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Valid Palindrome III](src/main/java/dynamic_programming/ValidPalindromeIII.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Palindrome Partitioning III](src/main/java/dynamic_programming/PalindromePartitioningIII.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Tiling a Rectangle with the Fewest Squares](src/main/java/dynamic_programming/TilingARectangle.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Longest Chunked Palindrome Decomposition](src/main/java/dynamic_programming/LongestChunkedPalindromeDecomposition.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Stone Game III](src/main/java/dynamic_programming/StoneGameIII.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Number of Ways to Stay in the Same Place After Some Steps](src/main/java/dynamic_programming/NumberOfWaysToStayInTheSamePlace.java) (Hard)
- [Toss Strange Coins](src/main/java/dynamic_programming/TossStrangeCoins.java) (Medium)
- [Knight Dialer](src/main/java/dynamic_programming/KnightDialer.java) (Medium)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Palindrome Removal](src/main/java/dynamic_programming/PalindromeRemoval.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Restore The Array](src/main/java/dynamic_programming/RestoreTheArray.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Cherry Pickup II](src/main/java/dynamic_programming/CherryPickupII.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Constrained Subsequence Sum](src/main/java/dynamic_programming/ConstrainedSubsequenceSum.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Largest Multiple of Three](src/main/java/dynamic_programming/LargestMultipleOfThree.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Largest Multiple of Three](src/main/java/dynamic_programming/MaximumProfitInJobScheduling.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Number of Music Playlists](src/main/java/dynamic_programming/NumberOfMusicPlaylists.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Paint House III](src/main/java/dynamic_programming/PaintHouseIII.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Shortest Path Visiting All Nodes](src/main/java/dynamic_programming/ShortestPathVisitingAllNodes.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Smallest Sufficient Team](src/main/java/dynamic_programming/SmallestSufficientTeam.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Stone Game IV](src/main/java/dynamic_programming/StoneGameIV.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Tallest Billboard](src/main/java/dynamic_programming/TallestBillboard.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Count Different Palindromic Subsequences](src/main/java/dynamic_programming/CountDifferentPalindromicSubsequences.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Number of Paths with Max Score](src/main/java/dynamic_programming/NumberOfPathsWithMaxScore.java) (Hard)

#### [Greedy](src/main/java/greedy)

- [Jump Game](src/main/java/greedy/JumpGame.java) (Medium)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Jump Game II](src/main/java/greedy/JumpGameII.java) (Hard)
- [Course Schedule III](src/main/java/greedy/CourseScheduleIII.java) (Medium)
- [GasStation](src/main/java/greedy/GasStation.java) (Medium)
- [Non-Overlapping Intervals](src/main/java/greedy/NonOverlappingIntervals.java) (Medium)
- [Minimum Number of Arrows to Burst Balloons](src/main/java/greedy/BurstBalloons.java) (Medium)
- [Queue Reconstruction By Height](src/main/java/greedy/QueueReconstructionByHeight.java) (Medium)
- [Task Scheduler](src/main/java/greedy/TaskScheduler.java) (Medium)
- [Maximum Length of Pair Chain](src/main/java/greedy/MaximumLengthOfPairChain.java) (Medium)
- [Lemonade Change](src/main/java/greedy/LemonadeChange.java) (Easy)
- [Score After Flipping Matrix](src/main/java/greedy/ScoreAfterFlippingMatrix.java) (Medium)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [IPO](src/main/java/greedy/IPO.java) (Hard)
- [String Without AAA or BBB](src/main/java/greedy/StringWithout3A3B.java) (Medium)
- [Boats to Save People](src/main/java/greedy/BoatsToSavePeople.java) (Medium)
- [Broken Calculator](src/main/java/greedy/BrokenCalculator.java) (Medium)
- [Two City Scheduling](src/main/java/greedy/TwoCityScheduling.java) (Easy)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Minimum Time to Build Blocks](src/main/java/greedy/MinimumTimeToBuildBlocks.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Reducing Dishes](src/main/java/greedy/ReducingDishes.java) (Hard)

#### [Hashing](src/main/java/hashing)

- [Anagrams](src/main/java/hashing/Anagrams.java) (Medium)
- [Group Anagrams](src/main/java/hashing/GroupAnagrams.java) (Medium)
- [Kdiff Pairs In a Array](src/main/java/hashing/KdiffPairsInanArray.java) (Easy)
- [Sort Character by Frequency](src/main/java/hashing/SortCharByFrequency.java) (Medium)
- [Two Sum](src/main/java/hashing/TwoSum.java) (Easy)
- [Valid Anagram](src/main/java/hashing/ValidAnagram.java) (Easy)
- [Maximum Size Subarray Sum Equals k](src/main/java/hashing/MaximumSizeSubarraySumEqualsk.java) (Medium)
- [Contiguous Array](src/main/java/hashing/ContiguousArray.java) (Medium)
- [Brick Wall](src/main/java/hashing/BrickWall.java) (Medium)
- [Partition Labels](src/main/java/hashing/PartitionLabels.java) (Medium)
- [Custom Sort String](src/main/java/hashing/CustomSortString.java) (Medium)
- [Short Encoding of Words](src/main/java/hashing/ShortEncodingOfWords.java) (Medium)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Substring with Concatenation of All Words](src/main/java/hashing/SubstringConcatenationOfWords.java) (Hard)
- [Distribute Candies](src/main/java/hashing/DistributeCandies.java) (Easy)
- [Groups of Special-Equivalent Strings](src/main/java/hashing/GroupsOfSpecialEquivalentStrings.java) (Easy)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Number of Atoms](src/main/java/hashing/NumberOfAtoms.java) (Hard)
- [Analyze User Website Visit Pattern](src/main/java/hashing/AnalyzeUserWebsiteVisitPattern.java) (Medium)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [String Transforms Into Another String](src/main/java/hashing/StringTransformsIntoAnotherString.java) (Hard)

#### [Heap](src/main/java/heap)

- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Sliding Window Maximum](src/main/java/heap/SlidingWindowMaximum.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [The Skyline Problem](src/main/java/heap/TheSkylineProblem.java) (Hard)
- [Meeting Rooms II](src/main/java/heap/MeetingRoomsII.java) (Medium)
- [Top K Frequent Words](src/main/java/heap/TopKFrequentWords.java) (Medium)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Candy](src/main/java/heap/Candy.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Smallest Rotation with Highest Score](src/main/java/heap/SmallestRotationWithHighestScore.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Maximum Frequency Stack](src/main/java/heap/FreqStack.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Reachable Nodes In Subdivided Graph](src/main/java/heap/ReachableNodesInSubdividedGraph.java) (Hard)
- [K Closest Points to Origin](src/main/java/heap/KClosestPointsToOrigin.java) (Medium)
- [Distant Barcodes](src/main/java/heap/DistantBarcodes.java) (Medium)

#### [Linked List](src/main/java/linked_list)

- [Intersection of two Linked-Lists](src/main/java/linked_list/IntersectionOfTwoLists.java) (Easy)
- [Linked List Cycle](src/main/java/linked_list/LinkedListCycle.java) (Easy)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Merge K Sorted Lists](src/main/java/linked_list/MergeKSortedLists.java) (Hard)
- [Merge Two Sorted List](src/main/java/linked_list/MergeTwoSortedList.java) (Easy)
- [Paliandrome List](src/main/java/linked_list/PaliandromeList.java) (Easy)
- [Reverse Linked List](src/main/java/linked_list/ReverseLinkedList.java) (Easy)
- [Delete Node in a Linked List](src/main/java/linked_list/DeleteNode.java) (Easy)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Reverse Nodes in k-Group](src/main/java/linked_list/ReverseNodesKGroup.java) (Hard)
- [Swap Nodes in Pairs](src/main/java/linked_list/SwapNodesInPairs.java) (Medium)
- [Middle of Linked List](src/main/java/linked_list/MiddleOfLinkedList.java) (Easy)
- [Split Linked List in Parts](src/main/java/linked_list/SplitLinkedListInParts.java) (Medium)
- [Next Greater Node In Linked List](src/main/java/linked_list/NextGreaterNodeInLinkedList.java) (Medium)

#### [Math](src/main/java/math)

- [Add Two Numbers](src/main/java/math/AddTwoNumbers.java) (Medium)
- [Count Primes](src/main/java/math/CountPrimes.java) (Easy)
- [Rotate Function](src/main/java/math/RotateFunction.java) (Medium)
- [Water and Jug Problem](src/main/java/math/WaterAndJugProblem.java) (Medium)
- [Add Digits](src/main/java/math/AddDigits.java) (Easy)
- [Excel Sheet Column Title](src/main/java/math/ExcelSheetColumnTitle.java) (Easy)
- [Roman to Integer](src/main/java/math/RomanToInteger.java) (Easy)
- [Bulb Switcher II](src/main/java/math/BulbSwitcherII.java) (Medium)
- [Global and Local Inversions](src/main/java/math/GlobalAndLocalInversions.java) (Medium)
- [Solve the Equation](src/main/java/math/SolveTheEquation.java) (Medium)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Couples Holding Hands](src/main/java/math/CouplesHoldingHands.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Reaching Points](src/main/java/math/ReachingPoints.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Nth Magical Number](src/main/java/math/NthMagicalNumber.java) (Hard)
- [Squirrel Simulation](src/main/java/math/SquirrelSimulation.java) (Medium)
- [Projection Area of 3D Shapes](src/main/java/math/ProjectionAreaOf3DShapes.java) (Easy)
- [Decoded String at Index](src/main/java/math/DecodedStringAtIndex.java) (Medium)
- [Base 7](src/main/java/math/Base7.java) (Easy)
- [Smallest Range I](src/main/java/math/SmallestRangeI.java) (Easy)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Largest Component Size by Common Factor](src/main/java/math/LargestComponentSizebyCommonFactor.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Super Washing Machines](src/main/java/math/SuperWashingMachines.java) (Hard)
- [Rectangle Overlap](src/main/java/math/RectangleOverlap.java) (Easy)
- [Nth Digit](src/main/java/math/NthDigit.java) (Easy)

#### [Reservoir Sampling](src/main/java/reservoir_sampling)

- [Random Pick Index](src/main/java/reservoir_sampling/RandomPickIndex.java) (Medium)

#### [Stack](src/main/java/stack)

- [Min Stack](src/main/java/stack/MinStack.java) (Easy)
- [Valid Parentheses](src/main/java/stack/ValidParentheses.java) (Easy)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Largest Rectangle In Histogram](src/main/java/stack/LargestRectangleInHistogram.java) (Hard)
- [Implement Queue using Stacks](src/main/java/stack/MyQueue.java) (Easy)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Maximal Rectangle](src/main/java/stack/MaximalRectangle.java) (Hard)
- [Exclusive Time of Functions](src/main/java/stack/ExclusiveTimeOfFunctions.java) (Medium)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Basic Calculator](src/main/java/stack/BasicCalculator.java) (Hard)
- [Decode String](src/main/java/stack/DecodeString.java) (Medium)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Longest Valid Parentheses](src/main/java/stack/LongestValidParentheses.java) (Hard)

#### [String](src/main/java/string)

- [First Unique Character In a String](src/main/java/string/FirstUniqueCharacterInAString.java) (Easy)
- [Repeated Substring Pattern](src/main/java/string/RepeatedSubstringPattern.java) (Easy)
- [Reverse Words In a String](src/main/java/string/ReverseWordsInAString.java) (Medium)
- [ReverseWords II](src/main/java/string/ReverseWordsII.java) (Medium)
- [String to Integer](src/main/java/string/StringToInteger.java) (Medium)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Text Justification](src/main/java/string/TextJustification.java) (Hard)
- [ZigZag Conversion](src/main/java/string/ZigZagConversion.java) (Medium)
- [Implement StrStr](src/main/java/string/ImplementStrStr.java) (Easy)
- [Excel Sheet Column Number](src/main/java/string/ExcelSheetColumnNumber.java) (Easy)
- [Compare Version Numbers](src/main/java/string/CompareVersionNumbers.java) (Easy)
- [Valid Palindrome](src/main/java/string/ValidPalindrome.java) (Easy)
- [Simplify Path](src/main/java/string/SimplifyPath.java) (Medium)
- [Permutation in String](src/main/java/string/PermutationInString.java) (Medium)
- [Add Binary](src/main/java/string/AddBinary.java) (Easy)
- [Valid Palindrome II](src/main/java/string/ValidPalindromeII.java) (Easy)
- [One Edit Distance](src/main/java/string/OneEditDistance.java) (Medium)
- [Count and Say](src/main/java/string/CountAndSay.java) (Easy)
- [Multiply Strings](src/main/java/string/MultiplyStrings.java) (Medium)
- [Longest Word in Dictionary through Deleting](src/main/java/string/LongestWordInDictonary.java) (Medium)
- [Isomorphic Strings](src/main/java/string/IsomorphicStrings.java) (Easy)
- [String Compression](src/main/java/string/StringCompression.java) (Easy)
- [Longest Common Prefix](src/main/java/string/LongestCommonPrefix.java) (Easy)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Find the Closest Palindrome](src/main/java/string/FindTheClosestPalindrome.java) (Hard)
- [Monotone Increasing Digits](src/main/java/string/MonotoneIncreasingDigits.java) (Medium)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Shortest Palindrome](src/main/java/string/ShortestPalindrome.java) (Hard)
- [Valid Word Abbreviation](src/main/java/string/ValidWordAbbreviation.java) (Easy)
- [Longest Palindrome](src/main/java/string/LongestPalindrome.java) (Easy)
- [Replace Words](src/main/java/string/ReplaceWords.java) (Medium)
- [Rotate String](src/main/java/string/RotateString.java) (Easy)
- [Keyboard Row](src/main/java/string/KeyboardRow.java) (Easy)
- [Student Attendance Record I](src/main/java/string/StudentAttendanceRecordI.java) (Easy)
- [Split Concatenated Strings](src/main/java/string/SplitConcatenatedStrings.java) (Medium)
- [Valid Word Square](src/main/java/string/ValidWordSquare.java) (Easy)
- [Reconstruct Original Digits from English](src/main/java/string/ReconstructOriginalDigitsFromEnglish.java) (Medium)
- [Push Dominoes](src/main/java/string/PushDominoes.java) (Medium)
- [Validate IP Address](src/main/java/string/ValidateIPAddress.java) (Medium)
- [Reverse String II](src/main/java/string/ReverseStringII.java) (Easy)
- [Find Words That Can Be Formed by Characters](src/main/java/string/FindWordsThatCanBeFormedbyCharacters.java) (Easy)
- [Minimum Add to Make Parentheses Valid](src/main/java/string/MinimumAddtoMakeParenthesesValid.java) (Medium)

#### [Tree](src/main/java/tree)

- [Binaray Tree Right Side View](src/main/java/tree/BinarayTreeRightSideView.java) (Medium)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Binary Tree Maximum Path Sum](src/main/java/tree/BinaryTreeMaximumPathSum.java) (Hard)
- [Boundary of Binary Tree](src/main/java/tree/BoundaryOfBinaryTree.java) (Medium)
- [Convert sorted array to BST](src/main/java/tree/ConvertSortedArrayToBST.java) (Medium)
- [Lowest Common Ancestor of a Binary Tree](src/main/java/tree/LCA.java) (Medium)
- [Lowest Common Ancestor of a BST](src/main/java/tree/LowestCommonAncestorBST.java) (Easy)
- [Most Frequent Subtree Sum](src/main/java/tree/MostFrequentSubtreeSum.java) (Medium)
- [Path Sum III](src/main/java/tree/PathSumIII.java) (Easy)
- [Convert Postorder and Inorder traversal to Binary Tree](src/main/java/tree/PostorderToBT.java) (Medium)
- [Convert Preorder and Inorder traversal to Binary Tree](src/main/java/tree/PreorderToBT.java) (Medium)
- [Sorted Array to BST](src/main/java/tree/SortedArrayToBST.java) (Medium)
- [Valid Binary Search Tree](src/main/java/tree/ValidBinarySearchTree.java) (Medium)
- [Largest BST Subtree](src/main/java/tree/LargestBSTSubtree.java) (Medium)
- [Closest Binary Search Tree Value](src/main/java/tree/ClosestBinarySearchTreeValue.java) (Easy)
- [Inorder Successor in BST](src/main/java/tree/InorderSuccessorInBST.java) (Medium)
- [Construct String From Binary Tree](src/main/java/tree/ConstructStringFromBinaryTree.java) (Easy)
- [Flatten Binary Tree to Linked List](src/main/java/tree/FlattenBinaryTree.java) (Medium)
- [Populating Next Right Pointers in Each Node](src/main/java/tree/NextRightPointer.java) (Medium)
- [Populating Next Right Pointers in Each Node II](src/main/java/tree/NextRightPointerII.java) (Medium)
- [Subtree of Another Tree](src/main/java/tree/SubtreeOfAnotherTree.java) (Easy)
- [Binary Tree Zigzag Level Order Traversal](src/main/java/tree/ZigZagTraversal.java) (Medium)
- [Binary Tree Inorder Traversal](src/main/java/tree/BinaryTreeInorderTraversal.java) (Medium)
- [Symmetric Tree](src/main/java/tree/SymmetricTree.java) (Easy)
- [Maximum Binary Tree](src/main/java/tree/MaximumBinaryTree.java) (Medium)
- [Find Bottom Left Tree Value](src/main/java/tree/FindBottomLeftTreeValue.java) (Medium)
- [Diameter of Binary Tree](src/main/java/tree/DiameterOfBinaryTree.java) (Easy)
- [Binary Tree Paths](src/main/java/tree/BinaryTreePaths.java) (Easy)
- [Sum of Left Leaves](src/main/java/tree/SumofLeftLeaves.java) (Easy)
- [Two Sum IV - Input is a BST](src/main/java/tree/TwoSumIV.java) (Easy)
- [Average of Levels in Binary Tree](src/main/java/tree/AverageOfLevelsInBinaryTree.java) (Easy)
- [Convert Binary Search Tree to Sorted Doubly Linked List](src/main/java/tree/BSTtoDoublyLinkedList.java) (Easy)
- [Same Tree](src/main/java/tree/SameTree.java) (Easy)
- [Binary Tree Longest Consecutive SequencefindMinDifference II](src/main/java/tree/BinaryTreeLongestConsecutiveSequenceII.java) (Medium)
- [Minimum Absolute Difference in BST](src/main/java/tree/MinimumAbsoluteDifferenceInBST.java) (Medium)
- [Equal Tree Partition](src/main/java/tree/EqualTreePartition.java) (Medium)
- [Split BST](src/main/java/tree/SplitBST.java) (Medium)
- [Closest Leaf in a Binary Tree](src/main/java/tree/ClosestLeafInABinaryTree.java) (Medium)
- [Maximum Width of Binary Tree](src/main/java/tree/MaximumWidthOfBinaryTree.java) (Medium)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Recover Binary Search Tree](src/main/java/tree/RecoverBinarySearchTree.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Binary Tree Postorder Traversal](src/main/java/tree/BinaryTreePostorderTraversal.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Serialize and Deserialize N-ary Tree](src/main/java/tree/SerializeAndDeserializeNAryTree.java) (Hard)
- [Convert BST to Greater Tree](src/main/java/tree/ConvertBSTToGreaterTree.java) (Easy)
- [All Nodes Distance K in Binary Tree](src/main/java/tree/AllNodesDistanceKInBinaryTree.java) (Medium)
- [All Possible Full Binary Trees](src/main/java/tree/AllPossibleFullBinaryTrees.java) (Medium)
- [Flip Equivalent Binary Trees](src/main/java/tree/FlipEquivalentBinaryTrees.java) (Medium)
- [Construct Binary Tree from String](src/main/java/tree/ConstructBinaryTreefromString.java) (Medium)
- [Find Largest Value in Each Tree Row](src/main/java/tree/FindLargestValueInEachTreeRow.java) (Medium)
- [Find Bottom Left Tree Value](src/main/java/tree/FindBottomLeftTreeValue.java) (Medium)
- [Maximum Level Sum of a Binary Tree](src/main/java/tree/MaximumLevelSumofABinaryTree.java) (Medium)
- [Leaf-Similar Trees](src/main/java/tree/LeafSimilarTrees.java) (Easy)
- [Binary Tree Tilt](src/main/java/tree/BinaryTreeTilt.java) (Easy)

#### [Two Pointers](src/main/java/two_pointers)

- [Four Sum](src/main/java/two_pointers/FourSum.java) (Medium)
- [Longest Substring Witout Repeats](src/main/java/two_pointers/LongestSubstringWitoutRepeats.java) (Medium)
- [Three Sum](src/main/java/two_pointers/ThreeSum.java) (Medium)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Trapping Rain Water](src/main/java/two_pointers/TrappingRainWater.java) (Hard)
- [3Sum Closest](src/main/java/two_pointers/ThreeSumClosest.java) (Medium)
- [Move Zeroes](src/main/java/two_pointers/MoveZeroes.java) (Easy)
- [Remove Duplicates](src/main/java/two_pointers/RemoveDuplicates.java) (Easy)
- [Remove Duplicates II](src/main/java/two_pointers/RemoveDuplicatesII.java) (Medium)
- [Minimum Size Subarray Sum](src/main/java/two_pointers/MinimumSizeSubarraySum.java) (Medium)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Minimum Window Substring](src/main/java/two_pointers/MinimumWindowSubstring.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Smallest Range](src/main/java/two_pointers/SmallestRange.java) (Hard)
- [Subarray Product Less Than K](src/main/java/two_pointers/SubarrayProductLessThanK.java) (Medium)
- [Number of Matching Subsequences](src/main/java/two_pointers/NumberOfMatchingSubsequences.java) (Medium)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Subarrays with K Different Integers](src/main/java/two_pointers/SubarraysWithKDifferentIntegers.java) (Hard)
- ![#f03c15](https://placehold.it/15/f03c15/000000?text=+) [Last Substring in Lexicographical Order](src/main/java/two_pointers/LastSubstringInLexicographicalOrder.java) (Hard)