Topological sorting / Topological Sort (Toposort)

Steps

A topological sorting algorithm AOV network topology configuration loop sequence primarily performs the following two-step, until there into until the degree of vertex 0.

(1) selecting one of the outputs of the vertex and 0;

(2) delete the vertices and edges from all the networks.

After the cycle, if the number of vertices less than the number of vertices in the output network, the output "circuit have" information, or the sequence of vertexes is a kind of topological output.

 

Guess you like

Origin www.cnblogs.com/hazel-wu/p/11282895.html
Recommended