64. Minimum Path Sum
Medium โ Dynamic Programming on Grid
Rows:
2
3
4
5
Cols:
2
3
4
5
Apply
Random grid
Play
Pause
Step
Reset
Speed:
Slow
Normal
Fast
Very Fast
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)