Search
⌘K

Leetcode 63. Unique Paths II

Count the number of distinct paths from the top-left to bottom-right of an m×n grid when you can only move right or down and cells marked 1 are impassable obstacles. This is a grid counting/DP problem with m,n ≤ 100 (answer ≤ 2×10^9).

Asked at:

Microsoft

Microsoft

Meta


Question Timeline

See when this question was last asked and where, including any notes left by other candidates.

Early November, 2025

Microsoft

Microsoft

Mid-level

Mid September, 2024

Meta

Mid-level

Variation of Unique Paths II - Print any path from start (0, 0) to end (rows-1, cols-1) in a matrix avoiding obstacles

Comments

Your account is free and you can post anonymously if you choose.