-
Take node with less weight to move forward
-
have mst weight and mst set
-
mst set keeps track of vertices already included
-
start with minimum weight node
-
key value map for all nodes, all values expect starting node have infinite value, Number.MAX_VALUE
-
the starting node will have 0 value
-
while mst node doesn’t include all vertices
Prims algo breakdown
https://www.geeksforgeeks.org/prims-minimum-spanning-tree-mst-greedy-algo-5/amp/- a rectangle has 4 vertices/ corners- counter strike connect all players using mst- In graph theory, a cut is a partition of the vertices of a graph into two disjoint subsets.[1] Any cut determines a cut-set, the set of edges that have one endpoint in each subset of the partition. These edges are said to cross…