We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents 4ed4ba0 + 742bc9d commit f9234f7Copy full SHA for f9234f7
Chapter4/mst.py
@@ -31,7 +31,7 @@ def mst(wg: WeightedGraph[V], start: int = 0) -> Optional[WeightedPath]:
31
return None
32
result: WeightedPath = [] # holds the final MST
33
pq: PriorityQueue[WeightedEdge] = PriorityQueue()
34
- visited: [bool] = [False] * wg.vertex_count # where we've been
+ visited: List[bool] = [False] * wg.vertex_count # where we've been
35
36
def visit(index: int):
37
visited[index] = True # mark as visited
0 commit comments