← Amazon questions

Shortest path using BFS

Filed under Amazon

Given an m x n binary grid where 0 represents an empty cell and 1 represents an obstacle, return the length of the shortest clear path from the top-left cell (0, 0) to the bottom-right cell (m-1…

You've read your 3 free write-ups

Sign up free to keep reading. Your account opens the first 10 questions of every company.

Related Amazon questions

Collected from public candidate posts and coding forums. Updated Nov 2026.