Evaluate the following statements and assign (T) to the true statements and (F) to the false ones. Assume a Depth First Search (DFS) algorithm was run, starting at A and the adjacency lists are in alphabetical order.
I. During the execution of the algorithm, 3 trees were needed to visit all vertices.
II. The vertex that goes from E to B is the only backword edge.
III. There are a total of 5 tree edges and 4 cross edges.
IV. The following order would be returned when applying a topological sort: B, C, E, A, D, F.
The correct sequence is:
a) T, T, F, F
b) F, F, T, T
c) T, T, F, T
d) T, F, T, F
e) None of the above.
Original idea by: Karla Florentino
Very nice question, but, topological sort exists only on acyclic graphs.
ResponderExcluir