DP:
Take a example, assume there are 5 nodes.
A,B,C,D,E
The program will run five times , k = A to E
for k = A:
Begin with node A , use Dijkstra's to travel the graph
then I get the shortest paths to B,C,D,E
that 4 value will be added to the dist
after k = E done.
=>
dist will store the ...