Java Software Structures, 4th Edition Exercise Solutions, Ch. 15
Chapter 15 Exercise Solutions
EX 15.1 Draw the undirected graph that is represented by the following:
vertices: 1, 2, 3, 4, 5, 6, 7
EX 15.2 Is the graph from Exercise 15.1 connected? Is it complete?
EX 15.3 List all of the cycles in the graph from Exercise 15.1.
1, 4, 2, 1
1, 4, 7, 3, 2, 1
EX 15.4 Draw a spanning tree for the graph of Exercise 15.1.
EX 15.5 Using the same data from Exercise 15.1, draw the resulting directed graph.
EX 15.6 Is the directed graph of Exercise 15.5 connected? Is it complete?
This directed graph is not connected because there are not paths from each node to
EX 15.7 List all of the cycles in the graph of Exercise 15.5.
EX 15.8 Draw a spanning tree for the graph of Exercise 15.5.
EX 15.9 Consider the weighted graph shown in Figure 15.12. List all of the possible
paths from vertex 2 to vertex 3 along with the total weight of each path. (Note:
The textbook exercise incorrectly references Figure 15.10.)
2, 5, 3 Weight: 4