Просмотр исходного кода

had an array with 1 element times 5 instead of an array with 5 of the same element

tarfeef101 6 лет назад
Родитель
Сommit
81b5902427
1 измененных файлов с 1 добавлено и 1 удалено
  1. 1 1
      a3/router.py

+ 1 - 1
a3/router.py

@@ -121,7 +121,7 @@ class graph:
         this.alist[dest - 1][src] = weight
             
     def rebuild(this):
-        this.sssp = [inf * 5]
+        this.sssp = [inf] * 5
         this.sssp[rid - 1] = 0
         
         curnode = rid - 1