Algorithm · Microsoft · Hard
Problem: Shortest Path in a Grid with at Most K Cells per Move You are given a grid with n rows and m columns: A . cell is open and may be visited. A # cell is blocked and may neither be entered nor passed through. The starting position is (sx, sy), and the destination is (tx, ty). All coordinates use 1-based indexing. For each move, select one of the four cardinal directions and travel between 1 and k cells in that direction. A move is invalid if it leaves the grid, lands…
Checking your access…