Graphs and DFS initial implementation