I am trying to implement Prim's algorithm using min-heap. I do not want to randomly choose the source/starting node, but want to sort the edges in non-decreasing order of weight to find the root node. I would like to have guidance as to how to go about it.
Aucun commentaire:
Enregistrer un commentaire