63. Unique Paths II
Medium — DP with Obstacles
Rows:
2
3
4
5
Cols:
2
3
4
5
Resize
Random obstacles
Clear
Play
Pause
Step
Reset
Speed:
Slow
Normal
Fast
Very Fast
Click any cell to toggle obstacle. Press "Play" to walk the DP.
Tip: click cells to toggle obstacles. Start/end cells cannot be toggled while playing.
Step
0 / 0
Cell
--
Formula
--
Result
--
Current cell
Above
Left
Obstacle
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)