Description: (1) on-demand storage structure, input containing n vertices (with characters in the name of that vertex) and e edges of the graph G
(2) specify arbitrary vertex x as the initial vertex of the graph G for the DFS traversal, output DFS (depth-first) vertex sequence (Hint: Use the stack to achieve DFS)
(3) specify arbitrary vertex x as the initial vertex of the graph G for the BFS (breadth traversal), the output sequence of BFS vertex (hint: the realization of the use of queue BFS)
(5) input vertex x, find graph G: If there is a vertex with x, then the deletion of the nodes and edges associated with them, and DFS traversal (3 steps) Otherwise output "does not exist x"
(6) to determine whether graph G is a connected graph, output "YES"/"NO"
(7) If I choose the storage structure is the adjacency matrix, the adjacency matrix of the information used to generate the adjacency list graph G
To Search:
- [graph1] - 1, map storage structure definition and
- [mat] - Depth-first search algorithm Matlab sour
- [graph] - Adjacency list graph representation of s
File list (Check if you may need any files):
第三题.c