Reading the Answer
The Optimal Value
The bottom-right DP cell answers the original optimization problem. It uses every item and the full capacity. This lesson reads that cell as the exact maximum achievable value while keeping clear that the subset itself still needs to be reconstructed.
Final cell
The final cell is dp at all items and full capacity, with value 9. Why: that state is exactly the original problem, not a helper problem. All earlier cells restrict either the item prefix or the available capacity, but this cell removes both restrictions and asks for the best value the instance can achieve.
Maximum value
No feasible subset can exceed value 9. Why: the recurrence has already compared every take-or-leave decision for every prefix and capacity on the way to this state. The number is therefore an optimum certificate for value, even before the traceback tells us which items achieve it.
Diagram note
The highlighted cell is recomputed from the same DP table as every other entry. It is useful to separate what the table proves from what it has not yet named: the table proves the optimal value, and traceback will recover the subset. The computation is exact for this zero-one integer instance and pseudo-polynomial in the capacity magnitude. Pixel positions are rounded for layout; every number shown is exact.