Longest Path Algorithm
Click anywhere in square to create vertex.
Select two vertices for directional edge.
Press the Longest Path button from 'A'.
Adjacency Graph structure
Dictionary of connected edges.
A: [B, C]
B: [C, D]
C: [D, E]
D: [F, G]
A: [B, C]
B: [C, D]
C: [D, E]
D: [F, G]
Longest Path Algorithm
Has to have a start and an end vertex.
Depth First Search algorithm.
Recursively assign the largest weight to each vertex.
Recursively assign the largest weight to each vertex.
After Depth First Search.
Count backwards from end vertex to start.
Longest Path. Done