Multi-Source BFS
0 lessons
4 problems
multi-source-bfs
Practice Problems
4 problems
Pacific Atlantic Water Flow
Not Started
Given a matrix of heights, find all cells from which water can flow to both the Pacific and Atlantic oceans.
Rotting Oranges
Free
Not Started
Given a grid where cells contain fresh oranges, rotten oranges, or are empty, determine the minimum time for all fresh oranges to rot via adjacency spreading.
Walls and Gates
Not Started
Given a grid with walls, gates, and empty rooms, fill each empty room with the distance to its nearest gate using multi-source BFS.
01 Matrix
Not Started
Given a binary matrix, find the distance of each cell to the nearest 0 using multi-source BFS.
