Exemplo n.º 1
0
/*
test data:
10 11
0 9 1
7 0	1
8 7	1
8 5	1
3 4	1
3 1	1
3 2	1
4 1	1
4 2	1
5 4	1
5 6	1

*/
func main() {
	g := listGraph.NewGraph()
	g.Print()
	fmt.Println("TopoOrder:")
	g.TopoOrder()
	g.Print()
}
Exemplo n.º 2
0
func main() {
	g := listGraph.NewGraph()
	g.Korasaju()
}
Exemplo n.º 3
0
func main() {
	g := listGraph.NewGraph()
	g.FindArticul()
}
Exemplo n.º 4
0
/*
test data:
9 10
0 1 6
0 2 4
0 3 5
1 4 1
2 4 1
3 5 2
4 6 9
4 7 7
5 7 4
6 8 2
7 8 4
*/
func main() {
	g := listGraph.NewGraph()
	g.Crucialpath()
}