Shortest Path in Binary Matrix
CodingOnsiteSoftware EngineerReported Aug, 2026
Company question banks are included with the Insider plan.
Given an n x n binary matrix grid, return the length of the shortest clear path in the matrix. If there is no clear path, return -1.
A clear path in a binary matrix is a path from the...