Anishukla / Hacktoberfest-2021-Data-Structures-and-Algorithms

This repository is mainly open to those who are looking to make some PRs for the Hacktoberfest 2021 event. In this repository, you can add programs on Data Structures and some useful algorithms for Competitive Programming.
51 stars 183 forks source link

Kruskals Algo for Graph #179

Open vedant-jain03 opened 3 years ago

vedant-jain03 commented 3 years ago

MST is a tree which has no cycle and minimum wieghted edge

Algo to implement MST:

Sort according to wieght; Using DSU try to find that respective edge form a cycle or not if not add the edge.

ghost commented 3 years ago

Hello... I have added Kruskal's algorithm in java and created a pull request. Please do consider my pull request.