Quick and easy breadth-first search

Learn how to traverse a social network or graphs

Marcus Knoph
Nov 16, 2020 · 7 min read
Cover image breadth first search — by rawpixel.com, apove, artistdesign13 and freepik

Breadth first search from here on known as BFS, is an algorithm for traversing a social network or graph. It starts at the root of the graph or a selected node, and from there it explores all of the neighbor nodes of that particular node before moving even farther down in the depth of the graph.