1281 - New Traffic System PDF (English) Statistics Forum Time Limit: 2 second(s) Memory Limit: 32 MB The country - Ajobdesh has a lot of problems in t ...
分类:
其他好文 时间:
2016-07-29 21:19:51
阅读次数:
187
Abandoned country Time Limit: 8000/4000 MS (Java/Others) Memory Limit: 65536/65536 K (Java/Others)Total Submission(s): 3449 Accepted Submission(s): 84 ...
分类:
其他好文 时间:
2016-07-25 08:10:23
阅读次数:
137
Connecting Universities Connecting Universities Treeland is a country in which there are n towns connected by n?-?1 two-way road such that it's possib ...
分类:
其他好文 时间:
2016-07-24 13:27:09
阅读次数:
125
题意t(t≤10)组数据,n(n≤1e5)个点,m(m≤1e6)条边,每条边长为w(w≤1e6),每条边的长度都不相等。求最小生成树的总长度及最小生成树上任意两点的距离期望值(保留两位小数)。样例输入14 61 2 12 3 23 4 34 1 41 3 52 4 6样例输出6 3.33思路由于每条 ...
分类:
其他好文 时间:
2016-07-23 16:41:03
阅读次数:
198
题目链接:http://acm.hdu.edu.cn/showproblem.php?pid=5723 Abandoned country Time Limit: 8000/4000 MS (Java/Others) Memory Limit: 65536/65536 K (Java/Others) ...
分类:
其他好文 时间:
2016-07-22 18:41:21
阅读次数:
125
题目说每条边权值都不一样,说明最小生成树是唯一的,不存在最小期望这一说。 然后就是先求出最小生成树,随便确定一个根节点,计算出每个点的子树有多少节点,记为c[x]。 指向x的这条边被统计的次数为c[x]*(n-c[x])。然后基本就可以算出答案了。 ...
分类:
其他好文 时间:
2016-07-21 23:44:08
阅读次数:
238
1、【HDU 5723】Abandoned country(最小生成树+树形dp) 题意:n(n≤100000)个城市,m(m≤1000000)条路,要修建(n-1)条路使这n个城市连通,题目中告诉我们修建每条路的费用,需要求两个问题:1、修建(n-1)条路的最小费用 2、路修建好了之后,任意两点之 ...
分类:
其他好文 时间:
2016-07-20 22:42:39
阅读次数:
255
在hadoop上创建目录/spark-study/users/gender=male/country=US/users.parquet(并且把文件put上去) code: package cn.spark.study.core.mycode_dataFrame; import org.apache. ...
分类:
其他好文 时间:
2016-07-20 01:07:17
阅读次数:
1158
Abandoned country Time Limit: 8000/4000 MS (Java/Others) Memory Limit: 65536/65536 K (Java/Others) Problem Description An abandoned country has n(n<=1 ...
分类:
其他好文 时间:
2016-07-19 20:43:50
阅读次数:
162
Description These are N cities in Spring country. Between each pair of cities there may be one transportation track or none. Now there is some cargo t ...
分类:
其他好文 时间:
2016-07-19 20:24:10
阅读次数:
161