epatrizio / cds

Data structures in C language
The Unlicense
0 stars 0 forks source link

Graph : paths between vertices #11

Open epatrizio opened 2 years ago

epatrizio commented 2 years ago

In graph_exists_path function, we determine if there is a path between 2 vertices. -> in algorithm implementation we use a hash set to remember visited vertices. But, by this method, it's impossible to know the path, we only know if it exists!

So, to know paths between vertices, we need to modify the algorithm and use a hash map (instead of a hash set) to remember visited vertices and origin vertices.

epatrizio commented 2 years ago