You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
letn=5letd=[[],[],[],[],[]]// 예시이므로 값을 채워놓지는 않았음// 최단거리 테이블 초기화// 1. 자기 자신으로 가는 거리는 0// 2. 가지 못하는 곳은 Int.max(무한을 의미)/* code */// k가 가장 바깥에서 루프를 도는 것은 자명한 사실이다.
for k in 0..<n {
for s in 0..<n {
for t in 0..<n {d[s][t]=min(d[s][t],d[s][k]+ d[k][t])}}}
The text was updated successfully, but these errors were encountered:
플로이드 알고리즘
The text was updated successfully, but these errors were encountered: