Let be a depth first search tree in an undirected graph . Vertices and are leaves of this tree . The degrees of both and in are at least . which one of the following statements is true?
View worked solution
Answer: D
In a Depth First Search (DFS) tree of an undirected graph , every edge of is either a tree edge or a back edge. There are no cross edges.
Let be a leaf of . Since is a leaf, its only tree edge is to its parent. Any other edge incident on in must be a back edge. Because there are no cross edges, all back edges from must connect to its ancestors in .
Therefore, all neighbors of in are ancestors of in . Since the ancestors of any vertex in a tree lie on a single unique path from the root to that vertex, all neighbors of must lie on the path in from the root to .
Let be the neighbor of that is closest to the root of . The path in from to contains all neighbors of . By adding the edge to this path, we obtain a cycle in that contains and all of its neighbors. Thus, Option D is always true.
Free practice · Your answers on this page are not saved.
