COMP 250 Lecture Notes - Lecture 27: Stable Marriage Problem, Hash Table, Adjacency List

10 views7 pages

Document Summary

Graphs are a generalization of things we"ve done up to now. Just as every linked list is a tree, where the head is the root, etc; every linked list and tree is a graph. It has nodes , just like in linked lists and other structures we"ve seen. It has references /pointers/edges from some nodes to other nodes. In this case, there is a pointer from e to f and a pointer from f to e. These correspond to something in the world, and you perform some computation with these numbers. A directed graph is a set of vertices (= nodes) An edge is an ordered pair of vertices: There is a start and an end vertex at each edge. In an undirected graph , the edges are unordered pairs (there is no start or end to the arrow). One webpage with a link on it to another webpage, that is a graph.

Get access

Grade+20% off
$8 USD/m$10 USD/m
Billed $96 USD annually
Grade+
Homework Help
Study Guides
Textbook Solutions
Class Notes
Textbook Notes
Booster Class
40 Verified Answers
Class+
$8 USD/m
Billed $96 USD annually
Class+
Homework Help
Study Guides
Textbook Solutions
Class Notes
Textbook Notes
Booster Class
30 Verified Answers

Related Documents