0% found this document useful (0 votes)
19 views

Topological Sorting

The document discusses topological sorting, which is a technique for ordering a directed acyclic graph. It can be applied to directed acyclic graphs but not undirected graphs or graphs with cycles. Topological sorting has a time complexity of O(V+E) and examples of its application include instruction scheduling in program compilation and determining prerequisite tasks. The document also asks multiple choice questions about topological sorting, its time complexity, applications, and detecting cycles in graphs.

Uploaded by

pubg pubg
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
19 views

Topological Sorting

The document discusses topological sorting, which is a technique for ordering a directed acyclic graph. It can be applied to directed acyclic graphs but not undirected graphs or graphs with cycles. Topological sorting has a time complexity of O(V+E) and examples of its application include instruction scheduling in program compilation and determining prerequisite tasks. The document also asks multiple choice questions about topological sorting, its time complexity, applications, and detecting cycles in graphs.

Uploaded by

pubg pubg
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 4

Shobitha Bhaskar

​Topic: Topological sorting

1 mark:

1.​Topological sort can be applied to which of the following graphsc

a) directed cyclic graph.

b) undirected acyclic graph

c) directed acyclic graph

d) undirected cyclic graph

2. Topological sorting is based on the implementation of technique:

a) Transform and Conquer

b) Decrease and conquer

c) Backtracking

d) Dynamic programming

3. Time complexity of topological sorting is

a)​ ​O(V+E).

b) ​O(V)
c) ​O(E)

d) ​O(V*E)

​2 marks:

1.Which of these is an example of topological sorting?

a) sorting lists

b) decision making and game theory

c)​ ​ instruction scheduling in program compilation

d) ​Numerical computations

2.​ A man wants to go to different places in the world. He has listed them
down all. But there are some places where he wants to visit before some
other places. What application of graph can he use to determine that?

a) Depth First Search

b) Breadth First Search

c) Topological Sorting

d) Dijkstra’s Shortest path algorithm


3 marks:

1.​What can be the applications of topological sorting?

a) Finding prerequisite of a task

b) Finding Deadlock in an Operating System

c) Finding Cycle in a graph

​d) All of the mentioned

2. Which of the following forms a directed cycle in the digraph?

a)c,d,e

b)b,c,d

c)a,c,d

​d)a,b,a

You might also like