64. Minimum Path Sum

Medium โ€” Dynamic Programming on Grid

Press "Play" or "Step" to fill the DP table.

Step

0 / 0

Cell

--

Formula

--

Min Sum

--
Current cell
Above
Left
Optimal path
Algorithm Complexity
2D DP
O(mn) / O(mn)
Time / Space: O(mn) / O(mn)
1D DP
O(mn) / O(n)
Time / Space: O(mn) / O(n)