Kruskal algo solved