home *** CD-ROM | disk | FTP | other *** search
- #include <LEDA/graph.h>
- #include <LEDA/graph_alg.h>
-
- declare2(GRAPH,int,int);
-
-
- main()
- {
-
- GRAPH(int,int) G;
-
- test_graph(G);
-
- node_array(int) compnum(G);
-
- real T;
-
- cout << "STRONG_COMPONENTS ";
- cout.flush();
- T = used_time();
- STRONG_COMPONENTS(G,compnum);
- cout << form(" %6.2f sec\n",used_time(T));
- newline;
-
- if (Yes("Ausgabe?"))
- { node v;
- forall_nodes(v,G)
- { G.print_node(v);
- cout << form(" comp = %3d \n", compnum[v]);
- }
- }
- newline;
-
- }
-