Kruskal's Algorithm
Kruskal's Algorithm
Steps In The Algorithm
- Sort all edges in increasing order of their edge weights.
- Pick the edge with the least weight.
- Check if the new edge creates a cycle or loop in the spanning tree.
- If it doesn't form the cycle, the include that edge in the minimum spanning tree.
- Repeat step 2-4 until |V| - 1 edges in the minimum spanning tree.
To learn more about Kruskal's algorithm, follow the link below:
Kruskal's Algorithm In Wikipedia