摘要:
还是畅通工程 Time Limit: 4000/2000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 22297 Accepted Submission(s): 9961 Problem Description 某省调查乡村交通状况,得到的统计表中列出了任意两村庄间的距离。... 阅读全文
摘要:
畅通工程 Time Limit: 1000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 14103 Accepted Submission(s): 5824 Problem Description 省政府“畅通工程”的目标是使全省任何两个村庄间都可以实现公路交通(... 阅读全文
摘要:
给定一个无向图,如果他的某个子图中,任意两个顶点都能互相连通并且是一棵树,那么这棵树就叫做生成树(spanning tree).如果边上有权值,那么使得边权和最小的生成树叫做最小生成树(MST,Minimum Spanning Tree)。1.prim版本的算法 1: #include 2: #define INF 10000001 3: #define N 10001 4... 阅读全文
摘要:
More is better Time Limit: 5000/1000 MS (Java/Others) Memory Limit: 327680/102400 K (Java/Others)Total Submission(s): 11872 Accepted Submission(s): 4398 Problem Description Mr Wang wants some boys to... 阅读全文