Graph edges
Queried shortest path
Just-relaxed cell
This 2D companion runs the unmodified Floyd-Warshall dynamic-programming recurrence โ the real O(nยณ) triple loop over pivot k, source i and target j โ against a small weighted directed graph, advancing one relaxation test at a time so each dist[i][j] = min(dist[i][j], dist[i][k]+dist[k][j]) comparison is visible as it happens. A live distance-matrix heatmap shows exactly which cell improves at each step, and clicking any two nodes reconstructs their actual shortest path by walking the next-hop matrix built alongside the distances, turning the algorithm's textbook pseudocode into something you watch run.