diff --git a/README.md b/README.md index c9d9219..66a2fca 100644 --- a/README.md +++ b/README.md @@ -57,8 +57,7 @@ Ace Coding Interview with 75 Qs - Must-do problem list for interview prep - Best for 1~3 month of prep time -
- Problems +Problems: | Array / String | | | | | ---------------------------------------------- | ---------------- | ------ | ------------------------ | @@ -83,88 +82,88 @@ Ace Coding Interview with 75 Qs [334]: ./src/page-4/334.%20Increasing%20Triplet%20Subsequence/increasingTriplet.ts [443]: ./src/page-5/443.%20String%20Compression/compress.ts -| Two Pointers | | | -| ------------------------------- | ---------------- | ------ | -| 283. Move Zeroes | [Solution][283] | Easy | -| 392. Is Subsequence | [Solution][392] | Easy | -| 11. Container With Most Water | [Solution][11] | Medium | -| 1679. Max Number of K-Sum Pairs | [Solution][1679] | Medium | +| Two Pointers | | | | +| ------------------------------- | ---------------- | ------ | ---- | +| 283. Move Zeroes | [Solution][283] | Easy | 詳解 | +| 392. Is Subsequence | [Solution][392] | Easy | 詳解 | +| 11. Container With Most Water | [Solution][11] | Medium | 詳解 | +| 1679. Max Number of K-Sum Pairs | [Solution][1679] | Medium | 詳解 | [283]: ./src/page-3/283.%20Move%20Zeroes/moveZeroes.ts [392]: ./src/page-4/392.%20Is%20Subsequence/isSubsequence.ts [11]: ./src/page-1/11.%20Container%20With%20Most%20Water/maxArea.ts [1679]: ./src/page-16/1679.%20Max%20Number%20of%20K-Sum%20Pairs/maxOperations.ts -| Sliding Window | | | -| ------------------------------------------------------------- | ---------------- | ------ | -| 643. Maximum Average Subarray I | [Solution][643] | Easy | -| 1456. Maximum Number of Vowels in a Substring of Given Length | [Solution][1456] | Medium | -| 1004. Max Consecutive Ones III | [Solution][1004] | Medium | -| 1493. Longest Subarray of 1's After Deleting One Element | [Solution][1493] | Medium | +| Sliding Window | | | | +| ------------------------------------------------------------- | ---------------- | ------ | ---- | +| 643. Maximum Average Subarray I | [Solution][643] | Easy | 詳解 | +| 1456. Maximum Number of Vowels in a Substring of Given Length | [Solution][1456] | Medium | 詳解 | +| 1004. Max Consecutive Ones III | [Solution][1004] | Medium | 詳解 | +| 1493. Longest Subarray of 1's After Deleting One Element | [Solution][1493] | Medium | 詳解 | [643]: ./src/page-6/643.%20Maximum%20Average%20Subarray%20I/findMaxAverage.ts [1456]: ./src/page-14/1456.%20Maximum%20Number%20of%20Vowels%20in%20a%20Substring%20of%20Given%20Length/maxVowels.ts [1004]: ./src/page-10/1004.%20Max%20Consecutive%20Ones%20III/longestOnes.ts [1493]: ./src/page-14/1493.%20Longest%20Subarray%20of%201's%20After%20Deleting%20One%20Element/longestSubarray.ts -| Prefix Sum | | | -| ------------------------------- | ---------------- | ---- | -| 1732. Find the Highest Altitude | [Solution][1732] | Easy | -| 724. Find Pivot Index | [Solution][724] | Easy | +| Prefix Sum | | | | +| ------------------------------- | ---------------- | ---- | ---- | +| 1732. Find the Highest Altitude | [Solution][1732] | Easy | 詳解 | +| 724. Find Pivot Index | [Solution][724] | Easy | 詳解 | [1732]: ./src/page-16/1732.%20Find%20the%20Highest%20Altitude/largestAltitude.ts [724]: ./src/page-7/724.%20Find%20Pivot%20Index/pivotIndex.ts -| Hash Map / Set | | | -| ---------------------------------------- | ---------------- | ------ | -| 2215. Find the Difference of Two Arrays | [Solution][2215] | Easy | -| 1207. Unique Number of Occurrences | [Solution][1207] | Easy | -| 1657. Determine if Two Strings Are Close | [Solution][1657] | Medium | -| 2352. Equal Row and Column Pairs | [Solution][2352] | Medium | +| Hash Map / Set | | | | +| ---------------------------------------- | ---------------- | ------ | ---- | +| 2215. Find the Difference of Two Arrays | [Solution][2215] | Easy | 詳解 | +| 1207. Unique Number of Occurrences | [Solution][1207] | Easy | 詳解 | +| 1657. Determine if Two Strings Are Close | [Solution][1657] | Medium | 詳解 | +| 2352. Equal Row and Column Pairs | [Solution][2352] | Medium | 詳解 | [2215]: ./src/page-21/2215.%20Find%20the%20Difference%20of%20Two%20Arrays/findDifference.ts [1207]: ./src/page-12/1207.%20Unique%20Number%20of%20Occurrences/uniqueOccurrences.ts [1657]: ./src/page-16/1657.%20Determine%20if%20Two%20Strings%20Are%20Close/closeStrings.ts [2352]: ./src/page-22/2352.%20Equal%20Row%20and%20Column%20Pairs/equalPairs.ts -| Stack | | | -| ---------------------------------- | ---------------- | ------ | -| 2390. Removing Stars From a String | [Solution][2390] | Medium | -| 735. Asteroid Collision | [Solution][735] | Medium | -| 394. Decode String | [Solution][394] | Medium | +| Stack | | | | +| ---------------------------------- | ---------------- | ------ | ---- | +| 2390. Removing Stars From a String | [Solution][2390] | Medium | 詳解 | +| 735. Asteroid Collision | [Solution][735] | Medium | 詳解 | +| 394. Decode String | [Solution][394] | Medium | 詳解 | [2390]: ./src/page-22/2390.%20Removing%20Stars%20From%20a%20String/removeStars.ts [735]: ./src/page-7/735.%20Asteroid%20Collision/asteroidCollision.ts [394]: ./src/page-4/394.%20Decode%20String/decodeString.ts -| Queue | | | -| --------------------------- | --------------- | ------ | -| 933. Number of Recent Calls | [Solution][933] | Easy | -| 649. Dota2 Senate | [Solution][649] | Medium | +| Queue | | | | +| --------------------------- | --------------- | ------ | ---- | +| 933. Number of Recent Calls | [Solution][933] | Easy | 詳解 | +| 649. Dota2 Senate | [Solution][649] | Medium | 詳解 | [933]: ./src/page-9/933.%20Number%20of%20Recent%20Calls/RecentCounter.ts [649]: ./src/page-6/649.%20Dota2%20Senate/predictPartyVictory.ts -| Linked List | | | -| --------------------------------------------- | ---------------- | ------ | -| 2095. Delete the Middle Node of a Linked List | [Solution][2095] | Medium | -| 328. Odd Even Linked List | [Solution][328] | Medium | -| 206. Reverse Linked List | [Solution][206] | Easy | -| 2130. Maximum Twin Sum of a Linked List | [Solution][2130] | Medium | +| Linked List | | | | +| --------------------------------------------- | ---------------- | ------ | ---- | +| 2095. Delete the Middle Node of a Linked List | [Solution][2095] | Medium | 詳解 | +| 328. Odd Even Linked List | [Solution][328] | Medium | 詳解 | +| 206. Reverse Linked List | [Solution][206] | Easy | 詳解 | +| 2130. Maximum Twin Sum of a Linked List | [Solution][2130] | Medium | 詳解 | [2095]: ./src/page-19/2095.%20Delete%20the%20Middle%20Node%20of%20a%20Linked%20List/deleteMiddle.ts [328]: ./src/page-4/328.%20Odd%20Even%20Linked%20List/oddEvenList.ts [206]: ./src/page-2/206.%20Reverse%20Linked%20List/reverseList.ts [2130]: ./src/page-20/2130.%20Maximum%20Twin%20Sum%20of%20a%20Linked%20List/pairSum.ts -| Binary Tree - DFS | | | -| -------------------------------------------- | ---------------- | ------ | -| 104. Maximum Depth of Binary Tree | [Solution][104] | Easy | -| 872. Leaf-Similar Trees | [Solution][872] | Easy | -| 1448. Count Good Nodes in Binary Tree | [Solution][1448] | Medium | -| 437. Path Sum III | [Solution][437] | Medium | -| 1372. Longest ZigZag Path in a Binary Tree | [Solution][1372] | Medium | -| 236. Lowest Common Ancestor of a Binary Tree | [Solution][236] | Medium | +| Binary Tree - DFS | | | | +| -------------------------------------------- | ---------------- | ------ | ---- | +| 104. Maximum Depth of Binary Tree | [Solution][104] | Easy | 詳解 | +| 872. Leaf-Similar Trees | [Solution][872] | Easy | 詳解 | +| 1448. Count Good Nodes in Binary Tree | [Solution][1448] | Medium | 詳解 | +| 437. Path Sum III | [Solution][437] | Medium | 詳解 | +| 1372. Longest ZigZag Path in a Binary Tree | [Solution][1372] | Medium | 詳解 | +| 236. Lowest Common Ancestor of a Binary Tree | [Solution][236] | Medium | 詳解 | [104]: ./src/page-2/104.%20Maximum%20Depth%20of%20Binary%20Tree/maxDepth.ts [872]: ./src/page-9/872.%20Leaf-Similar%20Trees/leafSimilar.ts @@ -173,80 +172,80 @@ Ace Coding Interview with 75 Qs [1372]: ./src/page-13/1372.%20Longest%20ZigZag%20Path%20in%20a%20Binary%20Tree/longestZigZag.ts [236]: ./src/page-3/236.%20Lowest%20Common%20Ancestor%20of%20a%20Binary%20Tree/lowestCommonAncestor.ts -| Binary Tree - BFS | | | -| ---------------------------------------- | ---------------- | ------ | -| 199. Binary Tree Right Side View | [Solution][199] | Medium | -| 1161. Maximum Level Sum of a Binary Tree | [Solution][1161] | Medium | +| Binary Tree - BFS | | | | +| ---------------------------------------- | ---------------- | ------ | ---- | +| 199. Binary Tree Right Side View | [Solution][199] | Medium | 詳解 | +| 1161. Maximum Level Sum of a Binary Tree | [Solution][1161] | Medium | 詳解 | [199]: ./src/page-2/199.%20Binary%20Tree%20Right%20Side%20View/rightSideView.ts [1161]: ./src/page-11/1161.%20Maximum%20Level%20Sum%20of%20a%20Binary%20Tree/maxLevelSum.ts -| Binary Search Tree | | | -| ----------------------------------- | --------------- | ------ | -| 700. Search in a Binary Search Tree | [Solution][700] | Easy | -| 450. Delete Node in a BST | [Solution][450] | Medium | +| Binary Search Tree | | | | +| ----------------------------------- | --------------- | ------ | ---- | +| 700. Search in a Binary Search Tree | [Solution][700] | Easy | 詳解 | +| 450. Delete Node in a BST | [Solution][450] | Medium | 詳解 | [700]: ./src/page-7/700.%20Search%20in%20a%20Binary%20Search%20Tree/searchBST.ts [450]: ./src/page-5/450.%20Delete%20Node%20in%20a%20BST/deleteNode.ts -| Graphs - DFS | | | -| ------------------------------------------------------------ | ---------------- | ------ | -| 841. Keys and Rooms | [Solution][841] | Medium | -| 547. Number of Provinces | [Solution][547] | Medium | -| 1466. Reorder Routes to Make All Paths Lead to the City Zero | [Solution][1466] | Medium | -| 399. Evaluate Division | [Solution][399] | Medium | +| Graphs - DFS | | | | +| ------------------------------------------------------------ | ---------------- | ------ | ---- | +| 841. Keys and Rooms | [Solution][841] | Medium | 詳解 | +| 547. Number of Provinces | [Solution][547] | Medium | 詳解 | +| 1466. Reorder Routes to Make All Paths Lead to the City Zero | [Solution][1466] | Medium | 詳解 | +| 399. Evaluate Division | [Solution][399] | Medium | 詳解 | [841]: ./src/page-8/841.%20Keys%20and%20Rooms/canVisitAllRooms.ts [547]: ./src/page-6/547.%20Number%20of%20Provinces/findCircleNum.ts [1466]: ./src/page-14/1466.%20Reorder%20Routes%20to%20Make%20All%20Paths%20Lead%20to%20the%20City%20Zero/minReorder.ts [399]: ./src/page-4/399.%20Evaluate%20Division/calcEquation.ts -| Graphs - BFS | | | -| ---------------------------------------- | ---------------- | ------ | -| 1926. Nearest Exit from Entrance in Maze | [Solution][1926] | Medium | -| 994. Rotting Oranges | [Solution][994] | Medium | +| Graphs - BFS | | | | +| ---------------------------------------- | ---------------- | ------ | ---- | +| 1926. Nearest Exit from Entrance in Maze | [Solution][1926] | Medium | 詳解 | +| 994. Rotting Oranges | [Solution][994] | Medium | 詳解 | [1926]: ./src/page-18/1926.%20Nearest%20Exit%20from%20Entrance%20in%20Maze/nearestExit.ts [994]: ./src/page-10/994.%20Rotting%20Oranges/orangesRotting.ts -| Heap / Priority Queue | | | -| ------------------------------------- | ---------------- | ------ | -| 215. Kth Largest Element in an Array | [Solution][215] | Medium | -| 2336. Smallest Number in Infinite Set | [Solution][2336] | Medium | -| 2542. Maximum Subsequence Score | [Solution][2542] | Medium | -| 2462. Total Cost to Hire K Workers | [Solution][2462] | Medium | +| Heap / Priority Queue | | | | +| ------------------------------------- | ---------------- | ------ | ---- | +| 215. Kth Largest Element in an Array | [Solution][215] | Medium | 詳解 | +| 2336. Smallest Number in Infinite Set | [Solution][2336] | Medium | 詳解 | +| 2542. Maximum Subsequence Score | [Solution][2542] | Medium | 詳解 | +| 2462. Total Cost to Hire K Workers | [Solution][2462] | Medium | 詳解 | [215]: ./src/page-2/215.%20Kth%20Largest%20Element%20in%20an%20Array/findKthLargest.ts [2336]: ./src/page-22/2336.%20Smallest%20Number%20in%20Infinite%20Set/SmallestInfiniteSet.ts [2542]: ./src/page-24/2542.%20Maximum%20Subsequence%20Score/maxScore.ts [2462]: ./src/page-23/2462.%20Total%20Cost%20to%20Hire%20K%20Workers/totalCost.ts -| Binary Search | | | -| -------------------------------------------- | ---------------- | ------ | -| 374. Guess Number Higher or Lower | [Solution][374] | Easy | -| 2300. Successful Pairs of Spells and Potions | [Solution][2300] | Medium | -| 162. Find Peak Element | [Solution][162] | Medium | -| 875. Koko Eating Bananas | [Solution][875] | Medium | +| Binary Search | | | | +| -------------------------------------------- | ---------------- | ------ | ---- | +| 374. Guess Number Higher or Lower | [Solution][374] | Easy | 詳解 | +| 2300. Successful Pairs of Spells and Potions | [Solution][2300] | Medium | 詳解 | +| 162. Find Peak Element | [Solution][162] | Medium | 詳解 | +| 875. Koko Eating Bananas | [Solution][875] | Medium | 詳解 | [374]: ./src/page-4/374.%20Guess%20Number%20Higher%20or%20Lower/guessNumber.ts [2300]: ./src/page-21/2300.%20Successful%20Pairs%20of%20Spells%20and%20Potions/successfulPairs.ts [162]: ./src/page-2/162.%20Find%20Peak%20Element/findPeakElement.ts [875]: ./src/page-9/875.%20Koko%20Eating%20Bananas/minEatingSpeed.ts -| Backtracking | | | -| ----------------------------------------- | --------------- | ------ | -| 17. Letter Combinations of a Phone Number | [Solution][17] | Medium | -| 216. Combination Sum III | [Solution][216] | Medium | +| Backtracking | | | | +| ----------------------------------------- | --------------- | ------ | ---- | +| 17. Letter Combinations of a Phone Number | [Solution][17] | Medium | 詳解 | +| 216. Combination Sum III | [Solution][216] | Medium | 詳解 | [17]: ./src/page-1/17.%20Letter%20Combinations%20of%20a%20Phone%20Number/letterCombinations.ts [216]: ./src/page-2/216.%20Combination%20Sum%20III/combinationSum3.ts -| DP - 1D | | | -| ------------------------------ | ---------------- | ------ | -| 1137. N-th Tribonacci Number | [Solution][1137] | Easy | -| 746. Min Cost Climbing Stairs | [Solution][746] | Easy | -| 198. House Robber | [Solution][198] | Medium | -| 790. Domino and Tromino Tiling | [Solution][790] | Medium | +| DP - 1D | | | | +| ------------------------------ | ---------------- | ------ | ---- | +| 1137. N-th Tribonacci Number | [Solution][1137] | Easy | 詳解 | +| 746. Min Cost Climbing Stairs | [Solution][746] | Easy | 詳解 | +| 198. House Robber | [Solution][198] | Medium | 詳解 | +| 790. Domino and Tromino Tiling | [Solution][790] | Medium | 詳解 | [1137]: ./src/page-11/1137.%20N-th%20Tribonacci%20Number/tribonacci.ts [746]: ./src/page-7/746.%20Min%20Cost%20Climbing%20Stairs/minCostClimbingStairs.ts @@ -265,41 +264,39 @@ Ace Coding Interview with 75 Qs [714]: ./src/page-7/714.%20Best%20Time%20to%20Buy%20and%20Sell%20Stock%20with%20Transaction%20Fee/maxProfit.ts [714-explanation]: ./src/page-7/714.%20Best%20Time%20to%20Buy%20and%20Sell%20Stock%20with%20Transaction%20Fee/README.md -| Bit Manipulation | | | -| --------------------------------------------- | ---------------- | ------ | -| 338. Counting Bits | [Solution][338] | Easy | -| 136. Single Number | [Solution][136] | Easy | -| 1318. Minimum Flips to Make a OR b Equal to c | [Solution][1318] | Medium | +| Bit Manipulation | | | | +| --------------------------------------------- | ---------------- | ------ | ---- | +| 338. Counting Bits | [Solution][338] | Easy | 詳解 | +| 136. Single Number | [Solution][136] | Easy | 詳解 | +| 1318. Minimum Flips to Make a OR b Equal to c | [Solution][1318] | Medium | 詳解 | [338]: ./src/page-4/338.%20Counting%20Bits/countBits.ts [136]: ./src/page-2/136.%20Single%20Number/singleNumber.ts [1318]: ./src/page-13/1318.%20Minimum%20Flips%20to%20Make%20a%20OR%20b%20Equal%20to%20c/minFlips.ts -| Trie | | | -| --------------------------------- | ---------------- | ------ | -| 208. Implement Trie (Prefix Tree) | [Solution][208] | Medium | -| 1268. Search Suggestions System | [Solution][1268] | Medium | +| Trie | | | | +| --------------------------------- | ---------------- | ------ | ---- | +| 208. Implement Trie (Prefix Tree) | [Solution][208] | Medium | 詳解 | +| 1268. Search Suggestions System | [Solution][1268] | Medium | 詳解 | [208]: ./src/page-2/208.%20Implement%20Trie%20(Prefix%20Tree)/Trie.ts [1268]: ./src/page-12/1268.%20Search%20Suggestions%20System/suggestedProducts.ts -| Intervals | | | -| ----------------------------------------------- | --------------- | ------ | -| 435. Non-overlapping Intervals | [Solution][435] | Medium | -| 452. Minimum Number of Arrows to Burst Balloons | [Solution][452] | Medium | +| Intervals | | | | +| ----------------------------------------------- | --------------- | ------ | ---- | +| 435. Non-overlapping Intervals | [Solution][435] | Medium | 詳解 | +| 452. Minimum Number of Arrows to Burst Balloons | [Solution][452] | Medium | 詳解 | [435]: ./src/page-5/435.%20Non-overlapping%20Intervals/eraseOverlapIntervals.ts [452]: ./src/page-5/452.%20Minimum%20Number%20of%20Arrows%20to%20Burst%20Balloons/findMinArrowShots.ts -| Monotonic Stack | | | -| ----------------------- | --------------- | ------ | -| 739. Daily Temperatures | [Solution][739] | Medium | -| 901. Online Stock Span | Solution | Medium | +| Monotonic Stack | | | | +| ----------------------- | --------------- | ------ | ---- | +| 739. Daily Temperatures | [Solution][739] | Medium | 詳解 | +| 901. Online Stock Span | Solution | Medium | 詳解 | [739]: ./src/page-7/739.%20Daily%20Temperatures/dailyTemperatures.ts -
- ## Advanced - Top Interview 150 Must-do List for Interview Prep @@ -309,8 +306,7 @@ Must-do List for Interview Prep - Best for 3+ months of prep time - Problems support high-quality editorials -
- Problems +Problems: | Array / String | | | | ------------------------------------------------------ | --------------- | ------ | @@ -591,8 +587,6 @@ Must-do List for Interview Prep [5]: ./src/page-1/5.%20Longest%20Palindromic%20Substring/longestPalindrome.ts -
- ## Impactful - Top 100 Liked 100 Best Rated Problems @@ -600,8 +594,7 @@ Must-do List for Interview Prep - 100 most liked problems by LeetCoders - Organized based on hot topics that help improve coding skills in interviews -
- Problems +Problems: | Backtracking | | | | ----------------------------------------- | -------------- | ------ | @@ -799,5 +792,3 @@ Must-do List for Interview Prep [136]: ./src/page-2/136.%20Single%20Number/singleNumber.ts [189]: ./src/page-2/189.%20Rotate%20Array/rotate.ts [238]: ./src/page-3/238.%20Product%20of%20Array%20Except%20Self/productExceptSelf.ts - -