Shortest Distance from All Buildings
317. Shortest Distance from All Buildings
You are given an m × n grid grid:
0represents empty land that can be walked through.1represents a building.2represents an obstacle th...
Example
Unlock to view complete problem details
and practice with sample input/output
Was this article helpful?
View Test Cases & Run Code requires membership
Standard Input
Execution Result:
