摘要:
#include #include #include #define MAXN 100#define MAXM 9900int N, M;struct Edge { int u,v; double weight; } edge[MAXM];int vertexs[MAXN];int parents[MAXN];double xs[MAXN];double ys[MAXN];int edge_cmp(const void* a, const void* b) { return (((struct Edge*)a)->weight - ((struct Edge*)b)->... 阅读全文
摘要:
#include #include #define MAX 100int N, M;struct Edge { int u,v; int weight; } edge[MAX];int vertexs[MAX];int parents[MAX];int edge_cmp(const void* a, const void* b) { return ((struct Edge*)a)->weight - ((struct Edge*)b)->weight; }int parents_find(int x) { int s; for(s = x; pa... 阅读全文