def METHOD_NAME(self, neighbors: list[Vertex], dists: list[float]):
    for n, dist in zip(neighbors, dists):
        self.edges[n] = dist
        self.flags.add(n)
        n.r_edges[self] = dist
    # Neighbors are ordered by distance
    self.worst_edge = n