Dynamic Programming
LC #62Medium
Unique Paths
Dynamic Programming
AmazonGoogleMetaBloombergMicrosoftProblem
Count unique paths from top-left to bottom-right of an m×n grid (only right or down moves).
mathdynamic-programming
Constraints
- ›1 ≤ m, n ≤ 100
Example
Input
m = 3, n = 7Output
28Why
From top-left to bottom-right of a 3×7 grid, moving only right or down