#include <bits/stdc++.h>
using namespace std;
const int N = 110;
struct Edge
{
int a, b, w;
bool operator< (const Edge &W)const{return w < W.w;}
}edge[N];
int p[N];
int n, m;
int find(int x)
{
if(p[x] != x) p[x] = find(p[x]);
return p[x];
}
int main()
{
whi...