Graphs - 1

Covered in this section:

Graphs are data structures consisting of nodes (also called vertices) and edges. They are used to model and solve problems involving objects and the relationships between them.

Key Terminology

Graph representations

What happens when vertex labels are not labelled from 0 to n-1 or label is not a number all toghether??, Suppose labels are strings, then we can use a map to store the index of each vertex. Example: unordered_map<string, vector<string>> adj;

Next Lesson