結果 : kruskal's algorithm in python code