Skip to content

Opening book details…

About this document

DFS and BFS Graph Traversal Explained by cs0814 is a document available to read on EtoBox.

The document explains two graph traversal algorithms: Depth First Search (DFS) and Breadth First Search (BFS). DFS uses a stack to explore as far as possible along a branch before backtracking, while BFS uses a queue to explore all neighbors at the present depth prior to moving on to nodes at the next depth level. Example implementations of both algorithms are provided using an adjacency list representation of a graph.

Author
cs0814
Language
EN