Shortest Path in a Grid with Obstacle Elimination
Asked at Meta · Coding Questions · Difficulty: Hard
Given a grid of `0` (empty) and `1` (wall) and an integer `k`, return the minimum number of steps to travel from the top-left `(0,0)` to the bottom-right `(m-1,n-1)`, moving 4-directionally, where you may pass through at most `k` wall cells along the way. Return `-1` if impossible.
Loading the problem…