Depth First Search (DFS) Explained: Algorithm, Examples, and Code

Veröffentlicht am: 05 Juli 2020
auf dem Kanal: Reducible
390,738
12k

In this video, I explain the fundamental ideas behind the Depth First Search (DFS) graph algorithm. We first introduce the concept of a graph traversal. We then go through several examples of DFS to provide intuition. Afterwards, we then go through both a recursive and iterative implementation with provided code. We discuss the differences between the implementation and also make a distinction between a preorder and post order DFS traversal. We then finish the video off with some practical and fun applications of depth first search in graph theory.

0:00 Intro and Preview
0:50 Graph Traversal
1:20 DFS Walkthrough and Examples
6:26 Recursive Implementation
11:08 Iterative Implementation
15:06 Preorder vs Postorder DFS
17:01 DFS Applications

Support:   / reducible  

This video wouldn't be possible without the open source manim library created by 3blue1brown: https://github.com/3b1b/manim

Here is link to the repository that contains the code used to generate the animations in this video: https://github.com/nipunramk/Reducible


Auf dieser Seite können Sie das Online-Video Depth First Search (DFS) Explained: Algorithm, Examples, and Code mit der Dauer stunde minuten sekunde in guter Qualität ansehen, das der Benutzer Reducible 05 Juli 2020 hochgeladen hat, den Link mit Freunden und Bekannten teilen, dieses Video wurde auf Youtube bereits 390,738 Mal angesehen und es wurde von 12 tausend den Zuschauern gefallen. Viel Spaß beim Betrachtenden Zuschauern gefallen!