Algorithm Implementation/Graphs/Depth-first search

In C++: