Kosaraju-Sharir’s algorithm and SCC Question
The Kosaraju-Sharir’s algorithm is usually used to find strongly connected components in a graph. Analyze which options below are valid tasks to use the algorithm, and mark the alternative with the correct options.
I. Validate and sort a sequence of actions which depend on each other, to make sure that prerequisites of a task can be completed before the given task is performed.
II. Group classes of a given Object-Oriented solution to isolate packages, in a graph where each class is a node and classes with any interaction have an edge.
III. Find the maximum number of processing steps of a given algorithm, in a graph where each algorithm step was considered as a node.
IV. Identify deadlocks in the operating system process execution, in a graph where nodes are processes and edges are created between processes when one waits the other for resources.
V. Optimize code compilation, identifying and removing code parts that are unreachable or adding parallelization to parts which are independent of the rest of the program, in a control flow graph (a graph with all possible execution paths).
a) Even options (II, IV)
b) Odd options (I, III, V)
c) III and V
d) II, IV, V
e) None of the above
Original idea by: Giorgio Rossa
Boa questão, mas me pareceu um pouco subjectiva.
ResponderExcluir