Explorar o código

embrace the stupidity

tarfeef101 %!s(int64=6) %!d(string=hai) anos
pai
achega
43a9867334
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      a3/router.py

+ 1 - 1
a3/router.py

@@ -150,7 +150,7 @@ class graph:
         curnode = rid - 1
         unvisited = [1] * 5
         
-        while(unvisited):
+        while(sum(unvisited)):
             # iterate on routers adjacent to curnode
             for i in range(0, 5):
                 # don't check curnode