
图论
竹二木
从业10年+,准备躺平的35+大龄程序猿,梦想是写代码写到60+。
展开
-
network 最小生成树 Kruskal 算法 poj 1861 zoj 1542
#include #include #include using namespace std; const int MAXN=1001; const int MAXM=15001; struct edge { int u,v,w; }edges[MAXM];原创 2011-07-22 22:20:24 · 896 阅读 · 0 评论 -
poj 1659 Havel—Hakimi定理
Havel—Hakimi定理:由非负数组成的非增序列s:d1,d2,···,dn(n>=2,d1>=1)是可图的,当仅当序列 s1:d2-1,d3-1,···,dd1+1 -1,dd1+2,····,dn 是可图的。序列s1中有n-1个非负数,s原创 2011-07-18 09:30:47 · 1289 阅读 · 0 评论