About Depth-First Search (DFS) and topological sorting, consider the following statements:
- The visited node order for the following graph and adjacency lists, starting with s, is s a c e b d
- While running a DFS on a directed graph, if from vertex u we visit a finished vertex v, then the edge (u, v) is a cross-edge
- If a topological sort exists for the vertices in a directed graph, then a DFS on the graph will produce no back edges
- A DFS in a directed graph always produces the same number of tree edges
- Suppose we perform a DFS on a directed graph G. If we remove all the back edges found, the resulting graph is acyclic
Which alternative lists all false statements and no true statement among I-V?
- I, II, III
- II, IV
- I, III, IV, V
- II
- None of the above
Original Idea by: Levy Chaves
No comments:
Post a Comment