Graph Representation in C++

How do we represent graphs in C ? I will explain three methods of representing graphs in C using Standard Template Library (STL)’s data structures: 1. Direct translation of the graph definition (Set of vertices, Set of Edges): 5:39 2. Adjacency list: 10:27 3. Adjacency matrix: 14:27 Comparison of all methods: 17:01 For each method we implement an algorithm solve the Konigsberg Bridge Problem, i.e. to check if a graph is Eulerian, that means if we can draw the graph and cover all edges exactly once without ever going backwards or disconnecting the pen and the paper. Link to all source codes: Check my other video on using Bazel to build C files in Visual Studio Code: Start a new C program using this Bazel template: Keep in touch with me:
Back to Top