Practice Problems

Daily Challenge: Paths Around the Walls (1500) Solve it to start a streak

bfs Problems

14 practice problems tagged bfs , from difficulty 1200 to 2200 — solve them in our in-browser judge with instant verdicts. Browse all problems.

Related: graphs trees bitmask heap

ProblemTopics Solvers Acceptance Difficulty
Height of the Tree bfs trees 0 1200
Fewest Hops bfs graphs 0 1300
Count the Lakes bfs graphs 0 1400
The Largest Lake bfs graphs 0 1400
Escape the Maze bfs graphs 0 1400
Two Teams bfs graphs 0 1500
Knight's Journey bfs graphs 0 1500
The Rot Spreads bfs graphs 0 1600
Diameter of a Tree bfs trees 0 1600
How Many Shortest Routes bfs graphs 0 1700
Free and Paid Roads bfs graphs 0 1800
The Shortest Loop bfs graphs 0 2000
Keys and Doors bfs graphs bitmask 0 2100
Rainwater on a Terrain bfs heap 0 2200