2017-11-22 11 views

답변

0

플로이드 -는 Warshall :

for(every vertex k that could possibly make distance from i to j shorter) 
     for(every possible vertex i) 
      for(every possible vertex j) 
       if(going through k can make the distance from i to j shorter) 
        you should go through k and update distance between i and j as you go