This is a code for depth first search. It creates a graph obect that you can add vertices and edges to. The DFS function returns a list of lists. This first list in the list is the root node/vertex. The second list are neighbors of the root node/vertex. The second list are nodes/vertices that are two path lengths away from the roots. And so on. You can alos print the adjacency list of the input graph.
-
Notifications
You must be signed in to change notification settings - Fork 0
mylesakin/Depth-First-Search
Folders and files
| Name | Name | Last commit message | Last commit date | |
|---|---|---|---|---|
Repository files navigation
About
No description, website, or topics provided.
Resources
Stars
Watchers
Forks
Releases
No releases published