Master reversing nodes in groups of k in a linked list — the classic hard interview problem asked at Amazon, Google, Facebook, and Microsoft. Learn both the elegant recursive solution and the iterative approach with clear pointer diagrams.
Master LeetCode 39 — Combination Sum by understanding the backtracking decision tree, why unlimited reuse is handled by staying at the same index, and how sorting enables early pruning. Includes Python and JavaScript solutions with line-by-line comments, a full visual dry run, common mistakes, and follow-up questions on LC 40, LC 216, and LC 377.
LC 46 — Permutations is the canonical backtracking problem every interviewer uses to test recursive thinking. Learn two clean approaches — the visited-array method and the in-place swap method — with a full decision-tree dry run for [1,2,3], the three most common interview mistakes, and real follow-up questions on LC 47 and LC 60.
LC 77 Combinations, LC 39 Combination Sum, and LC 40 Combination Sum II form a trilogy that every FAANG interviewer loves. Master the start-index pattern to enumerate selections without duplicates and the i+1 vs i reuse trick.
LC 51 N-Queens is the gold standard for testing backtracking, constraint propagation, and bit-mask elegance. Master row-by-row placement, three diagonal-tracking sets, and the bitmask trick that runs N=15 in milliseconds.
LC 37 Sudoku Solver is the most-asked constraint-satisfaction problem in tech interviews. Master row, column, and box bitsets, MRV heuristic ordering, and the cell-by-cell decision tree that solves any 9x9 grid in milliseconds.
LC 22 Generate Parentheses is the backtracking warm-up every FAANG interviewer reaches for. Master the open and close counter invariant, the Catalan number trail, and why a string-builder beats array joins for clean recursion.
LC 79 Word Search and LC 212 Word Search II ship in nearly every FAANG onsite. Master DFS with in-place visited marking, four-directional exploration, and the trie trick that turns multi-word search into a single traversal.
LC 17 Letter Combinations of a Phone Number is the cleanest cartesian-product backtracking template ever written. Master the digit-to-letter mapping, the per-position branching, and why the iterative BFS variant is asked at Amazon.
Master LeetCode 131 Palindrome Partitioning using backtracking with a precomputed palindrome DP table. Learn the decision tree, pruning, and FAANG interview tips.
Master Partition Equal Subset Sum (LC 416) and Partition to K Equal Sum Subsets (LC 698) with bucket backtracking, sorting tricks, and FAANG-grade pruning.
Solve the Knight's Tour with backtracking and Warnsdorff's heuristic. Visit every square exactly once on an n by n board with O(8^(n^2)) brute force tamed by smart move ordering.
LeetCode 526 Beautiful Arrangement with backtracking and bitmask DP. Learn how to generate divisibility-constrained permutations with FAANG interview tips.
M-coloring, bipartite check, and Hamiltonian path/cycle: backtracking on graphs with constraint propagation, ordering heuristics, and FAANG interview prep.
LC 450 Delete Node in a BST is a top FAANG interview problem testing all three deletion cases. Master the in-order successor strategy to pass BST questions at Amazon, Google, and Microsoft.
Generate all structurally unique BSTs storing values 1 to n using recursion plus memoization. LeetCode 95 is asked at Google, Amazon, and Meta to test divide-and-conquer reasoning on Catalan-number-sized search spaces.
LC 701 Insert into a BST traverses left or right based on value comparisons until finding a null position. The O(h) recursive solution is a BST fundamentals question tested at Amazon and Microsoft — always insert at a leaf.
LC 589 N-ary Tree Preorder and LC 590 Postorder Traversal generalize binary tree DFS to trees with any number of children. These easy problems build the foundation for harder n-ary tree problems asked at Amazon and Google.
LC 427 Construct Quad Tree builds a spatial partitioning tree from a 2D binary grid by recursively splitting non-uniform regions into four quadrants. This divide-and-conquer problem is tested at Amazon and Google and models real-world image compression and spatial indexing.