Skip to content

Instantly share code, notes, and snippets.

@lewdev
Last active July 6, 2024 12:46
Show Gist options
  • Select an option

  • Save lewdev/4afcafbfbabfd01c01defb069505a8e8 to your computer and use it in GitHub Desktop.

Select an option

Save lewdev/4afcafbfbabfd01c01defb069505a8e8 to your computer and use it in GitHub Desktop.
Top 75 LeetCode Questions to Save Your Time in JSON Array
/*
New Year Gift - Curated List of Top 75 LeetCode Questions to Save Your Time
https://www.teamblind.com/post/New-Year-Gift---Curated-List-of-Top-75-LeetCode-Questions-to-Save-Your-Time-OaM1orEU
*/
const top75problems = [
{ name: "Two Sum", category: "Array", problem: "two-sum" },
{ name: "Best Time to Buy and Sell Stock", category: "Array", problem: "best-time-to-buy-and-sell-stock" },
{ name: "Contains Duplicate", category: "Array", problem: "contains-duplicate" },
{ name: "Product of Array Except Self", category: "Array", problem: "product-of-array-except-self" },
{ name: "Maximum Subarray", category: "Array", problem: "maximum-subarray" },
{ name: "Maximum Product Subarray", category: "Array", problem: "maximum-product-subarray" },
{ name: "Find Minimum in Rotated Sorted Array", category: "Array", problem: "find-minimum-in-rotated-sorted-array" },
{ name: "Search in Rotated Sorted Array", category: "Array", problem: "search-in-rotated-sorted-array" },
{ name: "3Sum", category: "Array", problem: "3sum" },
{ name: "Container With Most Water", category: "Array", problem: "container-with-most-water" },
{ name: "Sum of Two Integers", category: "Binary", problem: "sum-of-two-integers" },
{ name: "Number of 1 Bits", category: "Binary", problem: "number-of-1-bits" },
{ name: "Counting Bits", category: "Binary", problem: "counting-bits" },
{ name: "Missing Number", category: "Binary", problem: "missing-number" },
{ name: "Reverse Bits", category: "Binary", problem: "reverse-bits" },
{ name: "Climbing Stairs", category: "Dynamic Programming", problem: "climbing-stairs" },
{ name: "Coin Change", category: "Dynamic Programming", problem: "coin-change" },
{ name: "Longest Increasing Subsequence", category: "Dynamic Programming", problem: "longest-increasing-subsequence" },
{ name: "Longest Common Subsequence", category: "Dynamic Programming", problem: "longest-common-subsequence" },
{ name: "Word Break Problem", category: "Dynamic Programming", problem: "word-break" },
{ name: "Combination Sum", category: "Dynamic Programming", problem: "combination-sum-iv" },
{ name: "House Robber", category: "Dynamic Programming", problem: "house-robber" },
{ name: "House Robber II", category: "Dynamic Programming", problem: "house-robber-ii" },
{ name: "Decode Ways", category: "Dynamic Programming", problem: "decode-ways" },
{ name: "Unique Paths", category: "Dynamic Programming", problem: "unique-paths" },
{ name: "Jump Game", category: "Dynamic Programming", problem: "jump-game" },
{ name: "Clone Graph", category: "Graph", problem: "clone-graph" },
{ name: "Course Schedule", category: "Graph", problem: "course-schedule" },
{ name: "Pacific Atlantic Water Flow", category: "Graph", problem: "pacific-atlantic-water-flow" },
{ name: "Number of Islands", category: "Graph", problem: "number-of-islands" },
{ name: "Longest Consecutive Sequence", category: "Graph", problem: "longest-consecutive-sequence" },
{ name: "Alien Dictionary", premium: 1, category: "Graph", problem: "alien-dictionary" },
{ name: "Graph Valid Tree", premium: 1, category: "Graph", problem: "graph-valid-tree" },
{ name: "Number of Connected Components in an Undirected Graph", premium: 1, category: "Graph", problem: "number-of-connected-components-in-an-undirected-graph" },
{ name: "Insert Interval", category: "Interval", problem: "insert-interval" },
{ name: "Merge Intervals", category: "Interval", problem: "merge-intervals" },
{ name: "Non-overlapping Intervals", category: "Interval", problem: "non-overlapping-intervals" },
{ name: "Meeting Rooms", premium: 1, category: "Interval", problem: "meeting-rooms" },
{ name: "Meeting Rooms II", premium: 1, category: "Interval", problem: "meeting-rooms-ii" },
{ name: "Reverse a Linked List", category: "Linked List", problem: "reverse-linked-list" },
{ name: "Detect Cycle in a Linked List", category: "Linked List", problem: "linked-list-cycle" },
{ name: "Merge Two Sorted Lists", category: "Linked List", problem: "merge-two-sorted-lists" },
{ name: "Merge K Sorted Lists", category: "Linked List", problem: "merge-k-sorted-lists" },
{ name: "Remove Nth Node From End Of List", category: "Linked List", problem: "remove-nth-node-from-end-of-list" },
{ name: "Reorder List", category: "Linked List", problem: "reorder-list" },
{ name: "Set Matrix Zeroes", category: "Matrix", problem: "set-matrix-zeroes" },
{ name: "Spiral Matrix", category: "Matrix", problem: "spiral-matrix" },
{ name: "Rotate Image", category: "Matrix", problem: "rotate-image" },
{ name: "Word Search", category: "Matrix", problem: "word-search" },
{ name: "Longest Substring Without Repeating Characters", category: "String", problem: "longest-substring-without-repeating-characters" },
{ name: "Longest Repeating Character Replacement", category: "String", problem: "longest-repeating-character-replacement" },
{ name: "Minimum Window Substring", category: "String", problem: "minimum-window-substring" },
{ name: "Valid Anagram", category: "String", problem: "valid-anagram" },
{ name: "Group Anagrams", category: "String", problem: "group-anagrams" },
{ name: "Valid Parentheses", category: "String", problem: "valid-parentheses" },
{ name: "Valid Palindrome", category: "String", problem: "valid-palindrome" },
{ name: "Longest Palindromic Substring", category: "String", problem: "longest-palindromic-substring" },
{ name: "Palindromic Substrings", category: "String", problem: "palindromic-substrings" },
{ name: "Encode and Decode Strings", premium: 1, category: "String", problem: "encode-and-decode-strings" },
{ name: "Maximum Depth of Binary Tree", category: "Tree", problem: "maximum-depth-of-binary-tree" },
{ name: "Same Tree", category: "Tree", problem: "same-tree" },
{ name: "Invert/Flip Binary Tree", category: "Tree", problem: "invert-binary-tree" },
{ name: "Binary Tree Maximum Path Sum", category: "Tree", problem: "binary-tree-maximum-path-sum" },
{ name: "Binary Tree Level Order Traversal", category: "Tree", problem: "binary-tree-level-order-traversal" },
{ name: "Serialize and Deserialize Binary Tree", category: "Tree", problem: "serialize-and-deserialize-binary-tree" },
{ name: "Subtree of Another Tree", category: "Tree", problem: "subtree-of-another-tree" },
{ name: "Construct Binary Tree from Preorder and Inorder Traversal", category: "Tree", problem: "construct-binary-tree-from-preorder-and-inorder-traversal" },
{ name: "Validate Binary Search Tree", category: "Tree", problem: "validate-binary-search-tree" },
{ name: "Kth Smallest Element in a BST", category: "Tree", problem: "kth-smallest-element-in-a-bst" },
{ name: "Lowest Common Ancestor of BST", category: "Tree", problem: "lowest-common-ancestor-of-a-binary-search-tree" },
{ name: "Implement Trie (Prefix Tree)", category: "Tree", problem: "implement-trie-prefix-tree" },
{ name: "Add and Search Word", category: "Tree", problem: "add-and-search-word-data-structure-design" },
{ name: "Word Search II", category: "Tree", problem: "word-search-ii" },
{ name: "Merge K Sorted Lists", category: "Heap", problem: "merge-k-sorted-lists" },
{ name: "Top K Frequent Elements", category: "Heap", problem: "top-k-frequent-elements" },
{ name: "Find Median from Data Stream", category: "Heap", problem: "find-median-from-data-stream" }
];
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/[email protected]/dist/css/bootstrap.min.css" integrity="sha384-Vkoo8x4CGsO3+Hhxv8T/Q5PaXtkKtu6ug5TOeNV6gBiFeWPGFN9MuhOf23Q9Ifjh" crossorigin="anonymous">
<div class="container">
<div>
<h1>Top 75 LeetCode Questions</h1>
<p>Curated List of Top 75 LeetCode Questions to Save Your Time from <a href="https://www.teamblind.com/post/New-Year-Gift---Curated-List-of-Top-75-LeetCode-Questions-to-Save-Your-Time-OaM1orEU">Blind post</a>.</p>
</div>
<div class="mb-3 row">
<div class="col">
Search: <input type="text" onkeyup="filter(this.value)"/> <span id="count"></span>
</div>
<div class="col text-right">
Category: <select id="cat" onchange="handleCategory(this.value)"></select>
</div>
</div>
<table class="table">
<thead>
<th>Name</th>
<th>Category</th>
<th>Difficulty</th>
<th>Solution</th>
</thead>
<tbody id="o"></tbody>
</table>
</div>
<script>
/*
New Year Gift - Curated List of Top 75 LeetCode Questions to Save Your Time
https://www.teamblind.com/post/New-Year-Gift---Curated-List-of-Top-75-LeetCode-Questions-to-Save-Your-Time-OaM1orEU
*/
const top75problems = [
{ name: "Two Sum", category: "Array", problem: "two-sum" },
{ name: "Best Time to Buy and Sell Stock", category: "Array", problem: "best-time-to-buy-and-sell-stock" },
{ name: "Contains Duplicate", category: "Array", problem: "contains-duplicate" },
{ name: "Product of Array Except Self", category: "Array", problem: "product-of-array-except-self" },
{ name: "Maximum Subarray", category: "Array", problem: "maximum-subarray" },
{ name: "Maximum Product Subarray", category: "Array", problem: "maximum-product-subarray" },
{ name: "Find Minimum in Rotated Sorted Array", category: "Array", problem: "find-minimum-in-rotated-sorted-array" },
{ name: "Search in Rotated Sorted Array", category: "Array", problem: "search-in-rotated-sorted-array" },
{ name: "3Sum", category: "Array", problem: "3sum" },
{ name: "Container With Most Water", category: "Array", problem: "container-with-most-water" },
{ name: "Sum of Two Integers", category: "Binary", problem: "sum-of-two-integers" },
{ name: "Number of 1 Bits", category: "Binary", problem: "number-of-1-bits" },
{ name: "Counting Bits", category: "Binary", problem: "counting-bits" },
{ name: "Missing Number", category: "Binary", problem: "missing-number" },
{ name: "Reverse Bits", category: "Binary", problem: "reverse-bits" },
{ name: "Climbing Stairs", category: "Dynamic Programming", problem: "climbing-stairs" },
{ name: "Coin Change", category: "Dynamic Programming", problem: "coin-change" },
{ name: "Longest Increasing Subsequence", category: "Dynamic Programming", problem: "longest-increasing-subsequence" },
{ name: "Longest Common Subsequence", category: "Dynamic Programming", problem: "longest-common-subsequence" },
{ name: "Word Break Problem", category: "Dynamic Programming", problem: "word-break" },
{ name: "Combination Sum", category: "Dynamic Programming", problem: "combination-sum-iv" },
{ name: "House Robber", category: "Dynamic Programming", problem: "house-robber" },
{ name: "House Robber II", category: "Dynamic Programming", problem: "house-robber-ii" },
{ name: "Decode Ways", category: "Dynamic Programming", problem: "decode-ways" },
{ name: "Unique Paths", category: "Dynamic Programming", problem: "unique-paths" },
{ name: "Jump Game", category: "Dynamic Programming", problem: "jump-game" },
{ name: "Clone Graph", category: "Graph", problem: "clone-graph" },
{ name: "Course Schedule", category: "Graph", problem: "course-schedule" },
{ name: "Pacific Atlantic Water Flow", category: "Graph", problem: "pacific-atlantic-water-flow" },
{ name: "Number of Islands", category: "Graph", problem: "number-of-islands" },
{ name: "Longest Consecutive Sequence", category: "Graph", problem: "longest-consecutive-sequence" },
{ name: "Alien Dictionary", premium: 1, category: "Graph", problem: "alien-dictionary" },
{ name: "Graph Valid Tree", premium: 1, category: "Graph", problem: "graph-valid-tree" },
{ name: "Number of Connected Components in an Undirected Graph", premium: 1, category: "Graph", problem: "number-of-connected-components-in-an-undirected-graph" },
{ name: "Insert Interval", category: "Interval", problem: "insert-interval" },
{ name: "Merge Intervals", category: "Interval", problem: "merge-intervals" },
{ name: "Non-overlapping Intervals", category: "Interval", problem: "non-overlapping-intervals" },
{ name: "Meeting Rooms", premium: 1, category: "Interval", problem: "meeting-rooms" },
{ name: "Meeting Rooms II", premium: 1, category: "Interval", problem: "meeting-rooms-ii" },
{ name: "Reverse a Linked List", category: "Linked List", problem: "reverse-linked-list" },
{ name: "Detect Cycle in a Linked List", category: "Linked List", problem: "linked-list-cycle" },
{ name: "Merge Two Sorted Lists", category: "Linked List", problem: "merge-two-sorted-lists" },
{ name: "Merge K Sorted Lists", category: "Linked List", problem: "merge-k-sorted-lists" },
{ name: "Remove Nth Node From End Of List", category: "Linked List", problem: "remove-nth-node-from-end-of-list" },
{ name: "Reorder List", category: "Linked List", problem: "reorder-list" },
{ name: "Set Matrix Zeroes", category: "Matrix", problem: "set-matrix-zeroes" },
{ name: "Spiral Matrix", category: "Matrix", problem: "spiral-matrix" },
{ name: "Rotate Image", category: "Matrix", problem: "rotate-image" },
{ name: "Word Search", category: "Matrix", problem: "word-search" },
{ name: "Longest Substring Without Repeating Characters", category: "String", problem: "longest-substring-without-repeating-characters" },
{ name: "Longest Repeating Character Replacement", category: "String", problem: "longest-repeating-character-replacement" },
{ name: "Minimum Window Substring", category: "String", problem: "minimum-window-substring" },
{ name: "Valid Anagram", category: "String", problem: "valid-anagram" },
{ name: "Group Anagrams", category: "String", problem: "group-anagrams" },
{ name: "Valid Parentheses", category: "String", problem: "valid-parentheses" },
{ name: "Valid Palindrome", category: "String", problem: "valid-palindrome" },
{ name: "Longest Palindromic Substring", category: "String", problem: "longest-palindromic-substring" },
{ name: "Palindromic Substrings", category: "String", problem: "palindromic-substrings" },
{ name: "Encode and Decode Strings", premium: 1, category: "String", problem: "encode-and-decode-strings" },
{ name: "Maximum Depth of Binary Tree", category: "Tree", problem: "maximum-depth-of-binary-tree" },
{ name: "Same Tree", category: "Tree", problem: "same-tree" },
{ name: "Invert/Flip Binary Tree", category: "Tree", problem: "invert-binary-tree" },
{ name: "Binary Tree Maximum Path Sum", category: "Tree", problem: "binary-tree-maximum-path-sum" },
{ name: "Binary Tree Level Order Traversal", category: "Tree", problem: "binary-tree-level-order-traversal" },
{ name: "Serialize and Deserialize Binary Tree", category: "Tree", problem: "serialize-and-deserialize-binary-tree" },
{ name: "Subtree of Another Tree", category: "Tree", problem: "subtree-of-another-tree" },
{ name: "Construct Binary Tree from Preorder and Inorder Traversal", category: "Tree", problem: "construct-binary-tree-from-preorder-and-inorder-traversal" },
{ name: "Validate Binary Search Tree", category: "Tree", problem: "validate-binary-search-tree" },
{ name: "Kth Smallest Element in a BST", category: "Tree", problem: "kth-smallest-element-in-a-bst" },
{ name: "Lowest Common Ancestor of BST", category: "Tree", problem: "lowest-common-ancestor-of-a-binary-search-tree" },
{ name: "Implement Trie (Prefix Tree)", category: "Tree", problem: "implement-trie-prefix-tree" },
{ name: "Add and Search Word", category: "Tree", problem: "add-and-search-word-data-structure-design" },
{ name: "Word Search II", category: "Tree", problem: "word-search-ii" },
{ name: "Merge K Sorted Lists", category: "Heap", problem: "merge-k-sorted-lists" },
{ name: "Top K Frequent Elements", category: "Heap", problem: "top-k-frequent-elements" },
{ name: "Find Median from Data Stream", category: "Heap", problem: "find-median-from-data-stream" }
];
cat.innerHTML = `<option value="">- All -</option>` + Object.keys(top75problems.reduce((prev, curr) => { prev[curr.category] = 1; return prev; }, {})).map(o => `<option>${o}</option>`);
let searchFilter = "";
let catFilter = "";
const handleCategory = val => {
catFilter = val;
render();
};
const filter = val => {
searchFilter = val.toLowerCase();
render();
};
const render = () => {
const list = top75problems.filter(a =>
(!catFilter || catFilter === a.category)
&& (!searchFilter || a.name.toLowerCase().includes(searchFilter))
);
o.innerHTML = list.map((p, i) => (`
<tr>
<td><a href="https://leetcode.com/problems/${p.problem}">${p.name}</a></td>
<td>${p.category}</td>
<td>-</td>
<td>-</td>
</tr>
`)).join("");
count.innerHTML = list.length + " items";
};
render();
</script>
[{
"_id": "623007312089261fc7c3743f",
"num": "1",
"name": "Two Sum",
"category": "Array",
"difficulty": "Easy",
"hasSolution": true,
"topics": "Array, Hash Table",
"path": "two-sum",
"completed": true,
"premium": false,
"discuss_post_url": "",
"code": "/**\n * @param {number[]} nums\n * @param {number} target\n * @return {number[]}\n */\nvar twoSum = function(nums, target) {\n const len = nums.length;\n const compliment = {};\n let num, diff;\n for (let i = 0; i < len; i++) {\n num = nums[i];\n diff = target - num;\n if (compliment[diff] !== void(0)) return [i, compliment[diff]];\n compliment[num] = i;\n }\n return [];\n};",
"neetcodeYt": "KLlXCFG5TnA"
}, {
"_id": "62300731474993f6f4ca24d3",
"num": "121",
"name": "Best Time to Buy and Sell Stock",
"category": "Array",
"difficulty": "Easy",
"topics": "Array, Dynamic Programming",
"path": "best-time-to-buy-and-sell-stock",
"hasSolution": true,
"completed": true,
"premium": false,
"discuss_post_url": "",
"code": "/**\n * @param {number[]} prices\n * @return {number}\n */\nvar maxProfit = function(prices) {\n const len = prices.length;\n let min = prices[0];\n let maxProfit = 0;\n for (let i = 1; i < len; i++) {\n min = Math.min(prices[i], min);\n maxProfit = Math.max(prices[i] - min, maxProfit);\n }\n return maxProfit;\n};",
"neetcodeYt": "1pkOgXD63yU"
}, {
"_id": "62300731c95fd426044c4786",
"name": "Contains Duplicate",
"num": "217",
"category": "Array",
"difficulty": "Easy",
"hasSolution": true,
"path": "contains-duplicate",
"premium": false,
"discuss_post_url": "",
"code": "",
"neetcodeYt": "3OamzN90kPg"
}, {
"_id": "6230073154326db5e06ce34c",
"num": "238",
"name": "Product of Array Except Self",
"category": "Array",
"difficulty": "Medium",
"hasSolution": true,
"topics": "Array, Prefix Sum",
"path": "product-of-array-except-self",
"completed": false,
"premium": false,
"discuss_post_url": "",
"code": "",
"neetcodeYt": "bNvIQI2wAjk"
}, {
"_id": "62300731982735fb17af3802",
"num": "53",
"name": "Maximum Subarray",
"category": "Array",
"difficulty": "Easy",
"topics": "Array, Divide and Conquer, Dynamic Programming",
"path": "maximum-subarray",
"hasSolution": true,
"completed": false,
"premium": false,
"discuss_post_url": "",
"code": "",
"neetcodeYt": "5WZl3MMT0Eg"
}, {
"_id": "62300731b24c9014c8cc4431",
"num": "152",
"name": "Maximum Product Subarray",
"category": "Array",
"difficulty": "Medium",
"topics": "Array, Dynamic Programming",
"path": "maximum-product-subarray",
"hasSolution": true,
"completed": false,
"premium": false,
"discuss_post_url": "",
"code": "",
"neetcodeYt": "lXVy6YWFcRM"
}, {
"_id": "623007316b4fed1697e37005",
"num": "153",
"name": "Find Minimum in Rotated Sorted Array",
"category": "Array",
"difficulty": "Medium",
"topics": "Array, Binary Search",
"path": "find-minimum-in-rotated-sorted-array",
"hasSolution": true,
"completed": false,
"premium": false,
"discuss_post_url": "",
"code": "",
"neetcodeYt": "nIVW4P8b1VA"
}, {
"_id": "62300731da6dd157bae75794",
"num": "33",
"name": "Search in Rotated Sorted Array",
"category": "Array",
"difficulty": "Medium",
"topics": "Array, Binary Search",
"path": "search-in-rotated-sorted-array",
"hasSolution": true,
"completed": false,
"premium": false,
"discuss_post_url": "",
"code": "",
"neetcodeYt": "U8XENwh8Oy8"
}, {
"_id": "623007317c6c28980ef22157",
"num": "15",
"name": "3Sum",
"category": "Array",
"difficulty": "Medium",
"topics": "Array, Two Pointers, Sorting",
"path": "3sum",
"hasSolution": true,
"completed": true,
"premium": false,
"discuss_post_url": "",
"code": "/**\n * @param {number[]} nums\n * @return {number[][]}\n */\nvar threeSum = function(nums) {\n const res = {};//hash\n const dups = {};\n const seen = {};\n const len = nums.length;\n for (let i = 0; i < len; i++) {\n if (!dups[nums[i]]) {\n dups[nums[i]] = true;\n for (let j = i + 1; j < len; j++) {\n const complement = -nums[i] - nums[j];\n if (typeof seen[complement] === \"number\" && seen[complement] === i) {\n const triplet = [nums[i], nums[j], complement];\n triplet.sort();\n res[triplet.join(\",\")] = triplet;\n }\n seen[nums[j]] = i;\n }\n }\n }\n return Object.keys(res).map(str => res[str]);\n};",
"neetcodeYt": "jzZsG8n2R9A"
}, {
"_id": "623007313f4b581efe85fe85",
"num": "11",
"name": "Container With Most Water",
"category": "Array",
"difficulty": "Medium",
"topics": "Array, Two Pointers, Greedy",
"path": "container-with-most-water",
"hasSolution": true,
"completed": true,
"premium": false,
"discuss_post_url": "",
"code": "/**\n * @param {number[]} height\n * @return {number}\n */\nvar maxArea = function(height) {\n const len = height.length;\n let max = 0;\n let index;\n const map = {};\n let left = 0;\n let right = len - 1;\n while (left < right) {\n const width = right - left;\n const minHeight = Math.min(height[left], height[right]);\n const volume = minHeight * width;\n max = Math.max(max, volume);\n if (height[left] < height[right]) left++;\n else right--;\n }\n return max;\n};",
"neetcodeYt": "UuiTKBwPgAo"
}, {
"_id": "62300731098c7550ef7a4a7b",
"num": "371",
"name": "Sum of Two Integers",
"category": "Binary",
"difficulty": "Easy",
"topics": "Math, Bit Manipulation",
"path": "sum-of-two-integers",
"hasSolution": true,
"completed": false,
"premium": false,
"discuss_post_url": "",
"code": "",
"neetcodeYt": "gVUrDV4tZfY"
}, {
"name": "Number of 1 Bits",
"category": "Binary",
"path": "number-of-1-bits",
"_id": "62300731f4c2097ef44fbc2e",
"neetcodeYt": "5Km3utixwZs",
"difficulty": "Easy"
}, {
"name": "Counting Bits",
"category": "Binary",
"path": "counting-bits",
"_id": "62300731e99b503b57dc6d94",
"neetcodeYt": "RyBM56RIWrM",
"difficulty": "Medium"
}, {
"name": "Missing Number",
"category": "Binary",
"path": "missing-number",
"_id": "6230073198affa3d833df958",
"neetcodeYt": "WnPLSRLSANE",
"difficulty": "Easy"
}, {
"name": "Reverse Bits",
"category": "Binary",
"path": "reverse-bits",
"_id": "623007319f0df6f1267df368",
"neetcodeYt": "UcoN6UjAI64",
"difficulty": "Easy"
}, {
"_id": "6230073199f84f372736558e",
"num": "70",
"name": "Climbing Stairs",
"neetcodeYt": "Y0lT9Fck7qI",
"category": "Dynamic Programming",
"difficulty": "Easy",
"topics": "Math, Dynamic Programming, Memoization",
"path": "climbing-stairs",
"hasSolution": true,
"completed": true,
"premium": false,
"discuss_post_url": "",
"code": "",
"testcases": ""
}, {
"_id": "6230073163ebf52008397d5e",
"num": "322",
"name": "Coin Change",
"neetcodeYt": "H9bfqozjoqs",
"category": "Dynamic Programming",
"difficulty": "Medium",
"topics": "Array, Dynamic Programming, Breadth-First Search",
"path": "coin-change",
"hasSolution": true,
"completed": true,
"premium": false,
"discuss_post_url": "",
"code": "var coinChange = function(coins, amount) {\n return recursion(coins, amount);\n};\n\nconst MAX = Number.MAX_SAFE_INTEGER;\nconst recursion = (coins, remain, memo = {}, depth = 1) => {\n if (remain < 0) return -1;\n if (remain === 0) return 0;\n\n if (memo[remain]) return memo[remain];\n\n let min = MAX;\n let count;\n for (const coin of coins) {\n count = recursion(coins, remain - coin, memo, depth + 1);\n if (count >= 0) min = Math.min(min, count + 1);\n }\n memo[remain] = min === MAX ? -1 : min;\n return memo[remain];\n}",
"testcases": ""
}, {
"name": "Longest Increasing Subsequence",
"category": "Dynamic Programming",
"path": "longest-increasing-subsequence",
"_id": "62300731f4f9bebbeff983ae",
"neetcodeYt": "cjWnW0hdF1Y",
"difficulty": "Medium"
}, {
"name": "Longest Common Subsequence",
"category": "Dynamic Programming",
"path": "longest-common-subsequence",
"_id": "62300731b52edae19b7a9eee",
"neetcodeYt": "Ua0GhsJSlWM",
"difficulty": "Medium"
}, {
"name": "Word Break Problem",
"category": "Dynamic Programming",
"path": "word-break",
"_id": "62300731200cea16e8b4bcaf",
"neetcodeYt": "Sx9NNgInc3A",
"difficulty": "Medium"
}, {
"_id": "6230073171f708e046b0a33c",
"num": "377",
"name": "Combination Sum IV",
"neetcodeYt": "",
"category": "Dynamic Programming",
"difficulty": "Medium",
"topics": "Array, Dynamic Programming",
"path": "combination-sum-iv",
"hasSolution": true,
"completed": false,
"premium": false,
"discuss_post_url": "",
"code": "",
"testcases": ""
}, {
"name": "House Robber",
"category": "Dynamic Programming",
"path": "house-robber",
"_id": "6230073103833a85a0685b68",
"neetcodeYt": "73r3KWiEvyk",
"difficulty": "Easy"
}, {
"name": "House Robber II",
"category": "Dynamic Programming",
"path": "house-robber-ii",
"_id": "62300731829cca118775fe2b",
"neetcodeYt": "rWAJCfYYOvM",
"difficulty": "Medium"
}, {
"name": "Decode Ways",
"category": "Dynamic Programming",
"path": "decode-ways",
"_id": "6230073187f0028438fa2ab5",
"neetcodeYt": "6aEyTjOwlJU",
"difficulty": "Medium"
}, {
"name": "Unique Paths",
"category": "Dynamic Programming",
"path": "unique-paths",
"_id": "623007311e32fecf4624522f",
"neetcodeYt": "IlEsdxuD4lY",
"difficulty": "Medium"
}, {
"name": "Jump Game",
"category": "Dynamic Programming",
"path": "jump-game",
"_id": "623007317e1ebeb3871e9458",
"neetcodeYt": "Yan0cv2cLy8",
"difficulty": "Medium"
}, {
"name": "Clone Graph",
"category": "Graph",
"path": "clone-graph",
"_id": "62300731fc0119defb10194f",
"neetcodeYt": "mQeF6bN8hMk",
"difficulty": "Medium"
}, {
"name": "Course Schedule",
"category": "Graph",
"path": "course-schedule",
"_id": "6230073188e6b7f163f14409",
"neetcodeYt": "EgI5nU9etnU",
"difficulty": "Medium"
}, {
"name": "Pacific Atlantic Water Flow",
"category": "Graph",
"path": "pacific-atlantic-water-flow",
"_id": "623007318399aea82103039e",
"neetcodeYt": "s-VkcjHqkGI",
"difficulty": "Medium"
}, {
"name": "Number of Islands",
"category": "Graph",
"path": "number-of-islands",
"_id": "623007312e28da5bc244af38",
"neetcodeYt": "pV2kpPD66nE",
"difficulty": "Medium"
}, {
"name": "Longest Consecutive Sequence",
"category": "Graph",
"path": "longest-consecutive-sequence",
"_id": "62300731f60e8edfc3d247f4",
"neetcodeYt": "P6RZZMu_maU",
"difficulty": "Hard"
}, {
"name": "Alien Dictionary",
"premium": 1,
"category": "Graph",
"path": "alien-dictionary",
"_id": "623007312cc6ff3f0929cbdd",
"neetcodeYt": "6kTZYvNNyps",
"difficulty": "Hard"
}, {
"name": "Graph Valid Tree",
"premium": 1,
"category": "Graph",
"path": "graph-valid-tree",
"_id": "62300731be369e07490ad2e7",
"neetcodeYt": "bXsUuownnoQ",
"difficulty": "Medium"
}, {
"name": "Number of Connected Components in an Undirected Graph",
"premium": 1,
"category": "Graph",
"path": "number-of-connected-components-in-an-undirected-graph",
"_id": "623007317c4a735b25a83338",
"neetcodeYt": "8f1XPm4WOUc",
"difficulty": "Medium"
}, {
"name": "Insert Interval",
"category": "Interval",
"path": "insert-interval",
"_id": "62300731a5e405728368d8c7",
"neetcodeYt": "A8NUOmlwOlM",
"difficulty": "Hard"
}, {
"name": "Merge Intervals",
"category": "Interval",
"path": "merge-intervals",
"_id": "6230073170bd536414b8685e",
"neetcodeYt": "44H3cEC2fFM",
"difficulty": "Medium"
}, {
"name": "Non-overlapping Intervals",
"category": "Interval",
"path": "non-overlapping-intervals",
"_id": "6230073157a419f073aa639f",
"neetcodeYt": "nONCGxWoUfM",
"difficulty": "Medium"
}, {
"name": "Meeting Rooms",
"premium": 1,
"category": "Interval",
"path": "meeting-rooms",
"_id": "62300731df62e94bfd3a1abc",
"neetcodeYt": "PaJxqZVPhbg",
"difficulty": "Easy"
}, {
"name": "Meeting Rooms II",
"premium": 1,
"category": "Interval",
"path": "meeting-rooms-ii",
"_id": "623007314031133a62ea3903",
"neetcodeYt": "FdzJmTCVyJU",
"difficulty": "Medium"
}, {
"name": "Reverse a Linked List",
"category": "Linked List",
"path": "reverse-linked-list",
"_id": "623007311969744674ef59ed",
"neetcodeYt": "G0_I-ZF0S38",
"difficulty": "Easy"
}, {
"name": "Detect Cycle in a Linked List",
"category": "Linked List",
"path": "linked-list-cycle",
"_id": "62300731ec9c8ed1afa7c4ff",
"neetcodeYt": "gBTe7lFR3vc",
"difficulty": "Easy"
}, {
"_id": "623007316e74efb970729e76",
"num": "21",
"name": "Merge Two Sorted Lists",
"category": "Linked List",
"difficulty": "Easy",
"topics": "Linked List, Recursion",
"path": "merge-two-sorted-lists",
"hasSolution": true,
"completed": true,
"premium": false,
"discuss_post_url": "",
"code": "/**\n * Definition for singly-linked list.\n * function ListNode(val, next) {\n * this.val = (val===undefined ? 0 : val)\n * this.next = (next===undefined ? null : next)\n * }\n */\n/**\n * @param {ListNode} list1\n * @param {ListNode} list2\n * @return {ListNode}\n */\nvar mergeTwoLists = function(list1, list2) {\n let head = null, node, curr, l1 = list1, l2 = list2;\n \n while (l1 || l2) {\n if (l1 && !l2) {\n node = new ListNode(l1.val);\n }\n else if (!l1 && l2) {\n node = new ListNode(l2.val);\n }\n else if (l1.val < l2.val) {\n node = new ListNode(l1.val, new ListNode(l2.val));\n }\n else {\n node = new ListNode(l2.val, new ListNode(l1.val));\n }\n if (!head) head = node;\n if (node.next) {\n if (!curr) curr = node.next;\n else {\n curr.next = node;\n curr = node.next;\n } \n }\n else {\n if (!curr) curr = node;\n else {\n curr.next = node;\n }\n }\n if (l1) l1 = l1.next;\n if (l2) l2 = l2.next;\n }\n return head;\n};",
"neetcodeYt": "XIdigk956u0"
}, {
"name": "Merge K Sorted Lists",
"category": "Linked List",
"path": "merge-k-sorted-lists",
"_id": "6230073107952a90c00cc693",
"neetcodeYt": "q5a5OiGbT6Q",
"difficulty": "Hard"
}, {
"_id": "623007318c011808f9e795e5",
"num": "19",
"name": "Remove Nth Node From End Of List",
"category": "Linked List",
"difficulty": "Medium",
"topics": "Linked List, Two Pointers",
"path": "remove-nth-node-from-end-of-list",
"hasSolution": true,
"completed": true,
"premium": false,
"discuss_post_url": "",
"code": "/**\n * Definition for singly-linked list.\n * function ListNode(val, next) {\n * this.val = (val===undefined ? 0 : val)\n * this.next = (next===undefined ? null : next)\n * }\n */\n/**\n * @param {ListNode} head\n * @param {number} n\n * @return {ListNode}\n */\nvar removeNthFromEnd = function(head, n) {\n let i = 1;\n let node = head;\n const list = [];\n while (node) {\n list.push(node);\n if (list.length > n + 1) list.shift();\n node = node.next;\n }\n const len = list.length;\n if (len === n + 1) {\n list[0].next = len > 2 ? list[2] : null;\n }\n else if (len === n) {\n head = len > 1 ? list[1] : null;\n }\n else head = null;\n return head;\n};",
"neetcodeYt": "XVuQxVej6y8"
}, {
"name": "Reorder List",
"category": "Linked List",
"path": "reorder-list",
"_id": "623007319c3684673b7b793b",
"neetcodeYt": "S5bfdUTrKLM",
"difficulty": "Medium"
}, {
"name": "Set Matrix Zeroes",
"category": "Matrix",
"path": "set-matrix-zeroes",
"_id": "62300731965fea721a1d6467",
"neetcodeYt": "T41rL0L3Pnw",
"difficulty": "Medium"
}, {
"name": "Spiral Matrix",
"category": "Matrix",
"path": "spiral-matrix",
"_id": "62300731708445bed6040a7e",
"neetcodeYt": "BJnMZNwUk1M",
"difficulty": "Medium"
}, {
"name": "Rotate Image",
"category": "Matrix",
"path": "rotate-image",
"_id": "6230073149eb02077956d5a1",
"neetcodeYt": "fMSJSS7eO1w",
"difficulty": "Medium"
}, {
"name": "Word Search",
"category": "Matrix",
"path": "word-search",
"_id": "62300731b87738813ebbf3c1",
"neetcodeYt": "pfiQ_PS1g8E",
"difficulty": "Medium"
}, {
"_id": "6230073156e7d57eee5a9c5b",
"num": "3",
"name": "Longest Substring Without Repeating Characters",
"category": "String",
"difficulty": "Medium",
"topics": "Hash Table, String, Sliding Window",
"path": "longest-substring-without-repeating-characters",
"hasSolution": true,
"completed": true,
"premium": false,
"discuss_post_url": "",
"code": "/**\n * @param {string} s\n * @return {number}\n */\nconst MAX_STR_LENGTH = 97;\nvar lengthOfLongestSubstring = function(s) {\n if (!s) return 0;\n if (s.length === 1) return 1;\n const size = s.length < MAX_STR_LENGTH ? s.length : MAX_STR_LENGTH;\n let charLen = size;\n for (; charLen > 0; --charLen) {\n const noDupSubstr = findNoDupSubstr(s, charLen);\n if (noDupSubstr) return noDupSubstr.length;\n }\n return 1;\n};\nconst findNoDupSubstr = (s, len) => {\n let i = 0, str;\n for (; i < s.length - len + 1; i++) {\n str = s.substr(i, len);\n if (!hasDuplicateChars(str)) {\n return str;\n }\n }\n return false;\n};\nconst hasDuplicateChars = str => {\n let i = 0, j, size = str.length, c;\n if (size === 1) return true;\n for (; i < size; i++) {\n for (j = 0; j < size; j++) {\n if (i !== j && str.charAt(i) === str.charAt(j)) {\n return true;\n }\n }\n }\n return false;\n};\n\n//abcabcbb\n// ^ ^\n//^ ^\n// ^ ^\n//abcdefghi",
"neetcodeYt": "wiGpQwVHdE0"
}, {
"name": "Longest Repeating Character Replacement",
"category": "String",
"path": "longest-repeating-character-replacement",
"_id": "6230073148faf0598ce53871",
"neetcodeYt": "gqXU1UyA8pk",
"difficulty": "Medium"
}, {
"name": "Minimum Window Substring",
"category": "String",
"path": "minimum-window-substring",
"_id": "62300731d776324ecfd745f9",
"neetcodeYt": "jSto0O4AJbM",
"difficulty": "Hard"
}, {
"name": "Valid Anagram",
"category": "String",
"path": "valid-anagram",
"_id": "623007316d2468f1fc1008a8",
"neetcodeYt": "9UtInBqnCgA",
"difficulty": "Easy"
}, {
"name": "Group Anagrams",
"category": "String",
"path": "group-anagrams",
"_id": "623007310cc78d8a7f699bb3",
"neetcodeYt": "vzdNOK2oB2E",
"difficulty": "Medium"
}, {
"_id": "6230073111799da6441d7f1a",
"num": "20",
"name": "Valid Parentheses",
"category": "String",
"difficulty": "Easy",
"topics": "String, Stack",
"path": "valid-parentheses",
"hasSolution": true,
"completed": true,
"premium": false,
"discuss_post_url": "",
"code": "/**\n * @param {string} s\n * @return {boolean}\n */\nconst OPEN = \"([{\";\nconst CLOSE = \")]}\";\nconst isOpen = c => OPEN.includes(c);\nconst isClose = c => CLOSE.includes(c);\n\nvar isValid = function(s) {\n const stack = [];\n const len = s.length;\n let c;\n for (let i = 0; i < len; i++) {\n c = s.charAt(i);\n if (isOpen(c)) stack.push(c);\n else if (isClose(c)) {\n const top = stack.pop();\n if (!top || OPEN.indexOf(top) !== CLOSE.indexOf(c)) {\n return false;\n }\n }\n }\n return stack.length === 0;\n};",
"neetcodeYt": "WTzjTskDFMg"
}, {
"_id": "62300731076e40945b2667d8",
"num": "125",
"name": "Valid Palindrome",
"category": "String",
"difficulty": "Easy",
"topics": "Two Pointers, String",
"path": "valid-palindrome",
"hasSolution": true,
"completed": true,
"premium": false,
"discuss_post_url": "",
"code": "/**\n * @param {string} s\n * @return {boolean}\n */\nvar isPalindrome = function(s) {\n s = s.toLowerCase().replace(/[^\\w\\d]|_/g, '');\n const len = s.length;\n const half = Math.ceil(len / 2);\n console.log(s, len, half);\n let i = 0;\n while (s.charAt(i) === s.charAt(len - i - 1) && i < half) {\n console.log(s.charAt(i), s.charAt(len - i - 1));\n i++;\n }\n return i === half;\n};\n",
"neetcodeYt": "jJXJ16kPFWg"
}, {
"_id": "62300731939fb664d8cf621b",
"num": "5",
"name": "Longest Palindromic Substring",
"category": "String",
"difficulty": "Medium",
"topics": "String, Dynamic Programming",
"path": "longest-palindromic-substring",
"hasSolution": true,
"completed": true,
"premium": false,
"discuss_post_url": "",
"code": "/**\n * @param {string} s\n * @return {string}\n */\nvar longestPalindrome = function(s) {\n if (!s || s.length < 1) return \"\";\n let start = 0, end = 0, len1, len2;\n for (let i = 0; i < s.length; i++) {\n len1 = expandAroundCenter(s, i, i);\n len2 = expandAroundCenter(s, i, i + 1);\n if (len1 > len2 && len1 > end - start) {\n start = i - Math.floor(len1 / 2);\n end = i + Math.floor(len1 / 2) + 1;\n }\n else if (len2 > len1 && len2 > end - start) {\n start = i - Math.floor(len2 / 2) + 1;\n end = i + Math.floor(len2 / 2) + 1;\n }\n }\n return s.substring(start, end);\n}\n\nfunction expandAroundCenter(s, left, right) {\n let L = left, R = right, len = 0;\n while (L >= 0 && R < s.length && s.charAt(L) === s.charAt(R)) {\n len = R - (L - 1);\n L--;\n R++;\n }\n return len;\n}",
"neetcodeYt": "XYQecbcd6_c"
}, {
"name": "Palindromic Substrings",
"category": "String",
"path": "palindromic-substrings",
"_id": "62300731cdccee47474e1ac2",
"neetcodeYt": "4RACzI5-du8",
"difficulty": "Medium"
}, {
"name": "Encode and Decode Strings",
"premium": 1,
"category": "String",
"path": "encode-and-decode-strings",
"_id": "623007311830f610280a907d",
"neetcodeYt": "B1k_sxOSgv8",
"difficulty": "Medium"
}, {
"name": "Maximum Depth of Binary Tree",
"category": "Tree",
"path": "maximum-depth-of-binary-tree",
"_id": "62300731d826b4776cd57d4a",
"neetcodeYt": "hTM3phVI6YQ",
"difficulty": "Easy"
}, {
"name": "Same Tree",
"category": "Tree",
"path": "same-tree",
"_id": "62300731a24bbcc641553052",
"neetcodeYt": "vRbbcKXCxOw",
"difficulty": "Easy"
}, {
"_id": "623007315aa63b853592a30c",
"num": "226",
"name": "Invert/Flip Binary Tree",
"category": "Tree",
"difficulty": "Easy",
"topics": "Tree, Depth-First Search, Breadth-First Search, Binary Tree",
"path": "invert-binary-tree",
"hasSolution": true,
"completed": true,
"premium": false,
"discuss_post_url": "",
"code": "/**\n * Definition for a binary tree node.\n * function TreeNode(val, left, right) {\n * this.val = (val===undefined ? 0 : val)\n * this.left = (left===undefined ? null : left)\n * this.right = (right===undefined ? null : right)\n * }\n */\n/**\n * @param {TreeNode} root\n * @return {TreeNode}\n */\nvar invertTree = function(root) {\n if (!root) return;\n //do left and right\n invertTree(root.left);\n invertTree(root.right);\n\n //flip\n const temp = root.right;\n root.right = root.left;\n root.left = temp;\n\n return root;\n};\n\n/*\nDepth First Search traversal.\n\nRecusive call \n\nT: O(n)\nS: O(1) maybe the recursive call will stack up to N if it's all on sided.\n*/",
"neetcodeYt": "OnSn2XEQ4MY"
}, {
"name": "Binary Tree Maximum Path Sum",
"category": "Tree",
"path": "binary-tree-maximum-path-sum",
"_id": "62300731345b961579617ec6",
"neetcodeYt": "Hr5cWUld4vU",
"difficulty": "Hard"
}, {
"name": "Binary Tree Level Order Traversal",
"category": "Tree",
"path": "binary-tree-level-order-traversal",
"_id": "623007319fcac18987585e8d",
"neetcodeYt": "6ZnyEApgFYg",
"difficulty": "Medium"
}, {
"name": "Serialize and Deserialize Binary Tree",
"category": "Tree",
"path": "serialize-and-deserialize-binary-tree",
"_id": "623007318f9f4d1d6499a4fa",
"neetcodeYt": "u4JAi2JJhI8",
"difficulty": "Hard"
}, {
"name": "Subtree of Another Tree",
"category": "Tree",
"path": "subtree-of-another-tree",
"_id": "62300731558924ef6fe36748",
"neetcodeYt": "E36O5SWp-LE",
"difficulty": "Easy"
}, {
"name": "Construct Binary Tree from Preorder and Inorder Traversal",
"category": "Tree",
"path": "construct-binary-tree-from-preorder-and-inorder-traversal",
"_id": "623007313ae85689714a0fec",
"neetcodeYt": "ihj4IQGZ2zc",
"difficulty": "Medium"
}, {
"name": "Validate Binary Search Tree",
"category": "Tree",
"path": "validate-binary-search-tree",
"_id": "623007313823ef8e1df06cd1",
"neetcodeYt": "s6ATEkipzow",
"difficulty": "Medium"
}, {
"name": "Kth Smallest Element in a BST",
"category": "Tree",
"path": "kth-smallest-element-in-a-bst",
"_id": "62300731ae013af3a5b8e79e",
"neetcodeYt": "5LUXSvjmGCw",
"difficulty": "Medium"
}, {
"name": "Lowest Common Ancestor of BST",
"category": "Tree",
"path": "lowest-common-ancestor-of-a-binary-search-tree",
"_id": "62300731607a504082dbf026",
"neetcodeYt": "gs2LMfuOR9k",
"difficulty": "Easy"
}, {
"name": "Implement Trie (Prefix Tree)",
"category": "Tree",
"path": "implement-trie-prefix-tree",
"_id": "6230073100b57e8309201eab",
"neetcodeYt": "oobqoCJlHA0",
"difficulty": "Medium"
}, {
"_id": "62300731a422a743314b14e7",
"num": "211",
"name": "Design Add and Search Words Data Structure",
"category": "Tree",
"difficulty": "Medium",
"topics": "String, Depth-First Search, Design, Trie",
"path": "design-add-and-search-words-data-structure",
"hasSolution": true,
"completed": true,
"premium": false,
"discuss_post_url": "",
"code": "\nvar WordDictionary = function() {\n this.trie = {};\n this.searchCache = {};\n};\n\n/**\n * @param {string} word\n * @return {void}\n */\nWordDictionary.prototype.addWord = function(word) {\n let node = this.trie;\n let c;\n for (let i = 0; i < word.length; i++) {\n c = word.charAt(i);\n if (!node[c]) node[c] = {};\n node = node[c];\n }\n node.word = true;\n\n //adding a word resets the cache\n this.searchCache = {};//reset cache\n};\n\n/** \n * @param {string} word\n * @return {boolean}\n */\nWordDictionary.prototype.search = function(word) {\n // console.log(\"search\", word);\n if (this.searchCache[word]) return this.searchCache[word].result;\n let node = this.trie;\n let c;\n for (let i = 0; i < word.length; i++) {\n c = word.charAt(i);\n if (c !== '.') {\n if (!node[c]) {\n this.searchCache[word] = {result: false};\n return false;\n }\n node = node[c];\n }\n else {\n const indexes = Object.keys(node);\n if (indexes.length === 0) return false;\n for (let j = 0; j < indexes.length; j++) {\n if (indexes[j] !== \"word\") {\n if (this.search(word.substr(0, i) + indexes[j] + (i < word.length - 1 ? word.substr(i + 1) : \"\"))) return true;\n }\n }\n this.searchCache[word] = {result: false};\n return false;\n }\n }\n const result = !!node.word;\n this.searchCache[word] = {result};\n // console.log(`Searched: \"${word}\"`, node, !!node.word);\n return result;\n};\n\n/** \n * Your WordDictionary object will be instantiated and called as such:\n * var obj = new WordDictionary()\n * obj.addWord(word)\n * var param_2 = obj.search(word)\n */"
}, {
"name": "Word Search II",
"category": "Tree",
"path": "word-search-ii",
"_id": "623007312496e93caa86158e",
"neetcodeYt": "asbcE9mZz_U",
"difficulty": "Hard"
}, {
"_id": "62300731eff65ce91bfcf90d",
"num": "347",
"name": "Top K Frequent Elements",
"category": "Heap",
"difficulty": "Medium",
"topics": "Array, Hash Table, Divide and Conquer, Sorting, Heap (Priority Queue), Bucket Sort, Counting, Quickselect",
"path": "top-k-frequent-elements",
"hasSolution": true,
"completed": true,
"premium": false,
"discuss_post_url": "",
"code": "/**\n * @param {number[]} nums\n * @param {number} k\n * @return {number[]}\n */\n var topKFrequent = function(nums, k) {\n const len = nums.length;\n if (len <= k) return nums;\n const map = {};\n for (const n of nums) {\n if (!map[n]) map[n] = 1;\n else map[n]++;\n }\n return Object.keys(map).map(num => ({num, count: map[num]})).sort((a, b) => b.count - a.count).splice(0, k).map(a => a.num);\n };",
"neetcodeYt": "YPTqKIgVk-k"
}, {
"name": "Find Median from Data Stream",
"category": "Heap",
"path": "find-median-from-data-stream",
"_id": "623007313fdd9e1a5f2f558f",
"neetcodeYt": "itmhHWaHupI",
"difficulty": "Hard"
}, {
"_id": "624a785e62a7aaa063ef6da4",
"num": "39",
"name": "Combination Sum",
"neetcodeYt": "GBKI9VSKdGg",
"category": "Array",
"difficulty": "Medium",
"topics": "Array, Backtracking",
"path": "combination-sum",
"hasSolution": true,
"completed": false,
"premium": false,
"discuss_post_url": "",
"code": "",
"testcases": ""
}
]
@dashingvinit
Copy link

Bro can you add the difficulty as well

@lewdev
Copy link
Author

lewdev commented Jul 6, 2024

See top-75-leetcode.json (just added) for the data I used for my app: https://lewdev.github.io/apps/code-challenge-tracker/

It includes the difficulty, topics, and YouTube IDs to NeetCode's videos.

Thanks for checking out my gist.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment