PROGRAMMING:Minimum spanning tree
Given a positive weighted undirected graph with n vertices, it is numbered from 0 to n-1. Please write a program to find the minimum spanning tree and calculate its cost.
###Input format:
**The input contains multiple sets of data** The first line of each group of data contains two integers n and E, both of which are no more than 200, representing the number of vertices and the number of edges of the graph respectively. Next, line e represents the information of each edge, and each line contains three non negative integers a, B, and C, where a and B represent the endpoint number of the edge, and C represents the weight. The sides are not arranged in end numbered order.
###Output format:
For each group of data, if there is a minimum spanning tree, an integer is output, which is the sum of the weights of each side of the minimum spanning tree; If there is no minimum spanning tree, output "there is no minimum spanning tree.".
###Input example:
```in
4 5
0 1 1
0 3 1
1 3 5
1 2 1
2 3 8
4 2
0 1 1
2 3 8
```
###Output example:
```out
three
There is no minimum spanning tree.
```
answer:If there is no answer, please comment
###Input format:
**The input contains multiple sets of data** The first line of each group of data contains two integers n and E, both of which are no more than 200, representing the number of vertices and the number of edges of the graph respectively. Next, line e represents the information of each edge, and each line contains three non negative integers a, B, and C, where a and B represent the endpoint number of the edge, and C represents the weight. The sides are not arranged in end numbered order.
###Output format:
For each group of data, if there is a minimum spanning tree, an integer is output, which is the sum of the weights of each side of the minimum spanning tree; If there is no minimum spanning tree, output "there is no minimum spanning tree.".
###Input example:
```in
4 5
0 1 1
0 3 1
1 3 5
1 2 1
2 3 8
4 2
0 1 1
2 3 8
```
###Output example:
```out
three
There is no minimum spanning tree.
```
answer:If there is no answer, please comment