← Quiz: Topological Sort: all 15 questions
Quiz: Topological Sort · Question 14 of 15
Can a directed graph have more than one valid topological order?
Can a directed graph have more than one valid topological order?
- A.Yes, whenever some nodes have no path between them, they can appear in either order
- B.No, the order is always unique
- C.Only if the graph has a cycle
- D.Only for undirected graphs
Answer & explanation
Correct answer: Yes, whenever some nodes have no path between them, they can appear in either order
In the course graph, Maths and C have no rule between them, so either may come first.
Can you get the rest right without peeking?
Take the timed Quiz: Topological Sort quiz free. Pass it to earn XP and count towards your certificate.
Start the quiz →