Nishant Gaurav·Nov 1Longest Common Subsequence: A New Pattern, the Same ThinkingThis chapter covers the first two steps: recursion and memoization. Tabulation comes next.
Nishant Gaurav·Oct 7Coin Change II: Counting Ways With Unlimited CoinsRod Cutting asks: what’s the maximum profit? Coin Change II asks: how many ways can you reach a target amount? The choice structure is the…
Nishant Gaurav·Oct 6Rod Cutting: Unbounded KnapsackChapter 7 introduced Unbounded Knapsack and ended with a promise: every problem in the unbounded family inherits the same structure, just…
suprith r b·Oct 6What Fits in 8 GB?Fractional and 0/1 knapsack, worked through with a phone that is almost full.
Nishant Gaurav·Sep 18Minimum Subset Sum DifferenceEvery chapter in this series has followed the same move: take the Knapsack structure, ask a different question, change one operation…
Nishant Gaurav·Sep 17Count of Subsets: One Word Changed. Everything FollowedChapter 3 ended with a hint. The shift from Knapsack to Subset Sum was a one-word change: max() became or. The structure stayed identical…
Nishant Gaurav·Sep 16Subset Sum and Equal Sum Partition: Same Pattern, Different QuestionChapter 2 ended with a promise: the 0/1 Knapsack pattern unlocks a chain of problems that all look different on the surface but share the…
Nishant Gaurav·Sep 150/1 Knapsack: The Pattern That Unlocks Half of All DP ProblemsIn Chapter 1, we built the DP mindset: recognise choices, find repeated subproblems, store answers instead of recomputing them. We didn’t…
Shriom Tripathi·Jun 4Beyond Prediction: Solving the Multiple Knapsack Problem at ScaleA better prediction only raises the ceiling on value; the Multiple Knapsack solver is what captures it. Because the multiple-knapsack....