Home▸Algorithms & AI▸0/1 Knapsack DP Table (2D)

🎒 0/1 Knapsack DP Table (2D)

Interactive 2D Canvas heatmap of the 0/1 knapsack dynamic-programming table: watch dp[i][w] fill cell by cell and backtrack the optimal packed items.

Algorithms & AI2DModerate60 FPS📱 Mobile-adapted⇄ 3D version
2d-knapsack ↗ Open standalone
⚙ Under the hood

Watch the 0/1 knapsack dynamic-programming table fill cell by cell on a 2D canvas heatmap. Step through the take-vs-skip recurrence, then watch backtracking trace the exact optimal set of items.

algorithmsdynamic programmingknapsackoptimizationcomputer science

2D · HTML5 Canvas 2D · 60 FPS target · runs fully client-side, no install

What did you find?

Add reproduction steps (optional)