Compare the subtle constraints across the Combination Sum family using one backtracking framework for candidates, deduplication, and the DP boundary.
67 articles
Compare the subtle constraints across the Combination Sum family using one backtracking framework for candidates, deduplication, and the DP boundary.
Explains sorting, pruning, and deduplication strategies for subset, permutation, and combination problems with duplicates.
Uses candidate sets to derive clear backtracking frameworks for subsets, permutations, and combinations.
Uses anagram problems to explain how counters and multisets model character frequencies and simplify solutions.
Uses array rotation and word reversal to show how composing a familiar reverse operation simplifies algorithms.
Solve LeetCode 148 by combining list splitting, fast and slow pointers, and merge sort in one comprehensive linked-list problem.
Explains fast and slow pointers for cycle detection, midpoint finding, and fixed-gap linked-list problems.
Use LeetCode 11 to derive the two-pointer solution and its correctness by reasoning about the search space.
Uses Two Sum and sorted-matrix search to explain how two pointers systematically shrink a search space.
Connects binary-tree traversal with backtracking through path tracking, undoing choices, and search trees.