Graphs can be undirected (where edges do not have a direction) or directed (digraph), where edges have a direction, as demonstrated in the following diagram:
A graph is strongly connected if there is a path in both directions between every pair of vertices. For example, C and D are strongly connected, while A and B are not strongly connected.
Graphs can also be unweighted (as we have noted so far) or weighted (in which the edges have weights—or values), as shown in the following diagram:
We can solve many problems ...