Breadth-First Search

Domain: Algorithms

🎯 Motivation

Explore all neighbours at the current depth before going deeper. Uses a queue. Finds the shortest path in unweighted graphs.

📋 Concrete Example

BFS on a graph: start at A, visit all neighbours (B, C), then their neighbours (D, E, F). Visits: A, B, C, D, E, F. Level by level.

🔗 Analogy

Ripple effect in a pond. When you drop a stone, the ripple spreads outward in concentric circles. BFS explores in expanding rings from the start.