(graph, a, b, edge)
| 45 | |
| 46 | |
| 47 | def connect(graph, a, b, edge): |
| 48 | # add the neighbors: |
| 49 | graph[a - 1].add_neighbor(graph[b - 1]) |
| 50 | graph[b - 1].add_neighbor(graph[a - 1]) |
| 51 | # add the edges: |
| 52 | graph[a - 1].add_edge(graph[b - 1], edge) |
| 53 | graph[b - 1].add_edge(graph[a - 1], edge) |
| 54 | |
| 55 | |
| 56 | def prim(graph: list, root: Vertex) -> list: |
nothing calls this directly
no test coverage detected