Once every cell is filled, the final state contains the optimal value. The table is not an approximation or a solver trace; it is the recurrence written out. This lesson reads the whole grid as the completed computation.
highlighted = computed this step
Filled table
The full table has 5 rows and 8 columns. Why: every item prefix is paired with every capacity.
all subproblems filled
Answer location
The bottom-right cell is 9. Why: it uses all items and the full capacity.
dp[n,W]=9
Diagram note
Every entry in the table is recomputed by the knapsack recurrence. Pixel positions are rounded for layout; every number shown is exact.