Quiz 10, 11/1
As discussed in the Lab 10 document, the
myListGraph class
can be easily modified to represent edge-weighted graphs by using the
EdgeLinkList class to
represent neighbors.
Here is the beginnings of the myWeightedGraph class.
The only difference between the data members of this class and the data members of the
myListGraph class
is that we use
protected EdgeLinkList[] Edges;
to define the adjacency list.
Complete the two methods addEdge and getWeight, whose code is missing.