摘要: #include#include#define N 100010int father[N],link[N];int find(int x) {if(x!=father[x]) {int h=father[x];father[x]=find(father[x]);link[x]=(link[x]+li... 阅读全文
posted @ 2013-11-24 22:27 HYDhyd 阅读(120) 评论(0) 推荐(0) 编辑
摘要: 不会写果断看答案http://cavenkaka.iteye.com/blog/1489588#include#include#define N 50010int father[N],link[N];int find(int x) {if(x!=father[x]) {int h=father[x]... 阅读全文
posted @ 2013-11-24 18:20 HYDhyd 阅读(98) 评论(0) 推荐(0) 编辑