码迷,mamicode.com
首页 >  
搜索关键字:dragon balls    ( 484个结果
hdu3635 Dragon Balls
Problem Description Five hundred years later, the number of dragon balls will increase unexpectedly, so it's too difficult for Monkey King(WuKong) to gather all of the dragon balls together.  ...
分类:其他好文   时间:2015-05-11 14:53:46    阅读次数:130
UVA - 679 Dropping Balls 规律
题目大意:给出一棵完全二叉树,每个节点上都有一个开关,刚开始开关都是开的,球经过该节点后开关就关上了(根节点除外)。如果球经过该节点的兄弟节点,那么该节点的开关就又开了 现在往根节点放球,优先选择左边的节点走,如果左边的节点的开关关了,就选择右边的。球落到叶节点后就继续另一颗球,问第n颗球落到了哪个叶节点上解题思路:其实这题蛮水的,因为是二叉树,所以可以由球的奇偶行来判断球往哪个分支走,如果n %...
分类:其他好文   时间:2015-05-11 00:05:03    阅读次数:205
Codeforces Round #162 (Div. 1) C Choosing Balls dp
//dp[i] 表示以颜色为i结尾的最大值 //dp[i] = max(dp[i] , dp[i] + a*v[i] ,other_max + b*v[i]) ; //为除颜色i以外的其它颜色的最大值 #include #include #include using namespace std ; const int maxn = 100010 ; const __int64 in...
分类:其他好文   时间:2015-05-08 18:10:41    阅读次数:125
hduoj 4710 Balls Rearrangement 2013 ACM/ICPC Asia Regional Online —— Warmup
http://acm.hdu.edu.cn/showproblem.php?pid=4710Balls RearrangementTime Limit: 6000/3000 MS (Java/Others)Memory Limit: 32768/32768 K (Java/Others) Total...
分类:其他好文   时间:2015-04-29 23:26:15    阅读次数:164
11292 - Dragon of Loowater
例题1  勇者斗恶龙(The Dragon of Loowater, UVa 11292) 你的王国里有一条n个头的恶龙,你希望雇一些骑士把它杀死(即砍掉所有头)。村里有m个骑士可以雇佣,一个能力值为x的骑士可以砍掉恶龙一个直径不超过x的头,且需要支付x个金币。如何雇佣骑士才能砍掉恶龙的所有头,且需要支付的金币最少?注意,一个骑士只能砍一个头(且不能被雇佣两次)。 【输入格式】...
分类:其他好文   时间:2015-04-28 09:48:04    阅读次数:129
TED_Topic7:How we unearthed the spinosaurus
By Nizar Ibrahim A 50-foot-long carnivore who hunted its prey in rivers 97 million years ago, the spinosaurus is a "dragon from deep time." Paleontolo...
分类:其他好文   时间:2015-04-27 15:04:21    阅读次数:112
HDU5194 DZY Loves Balls【排列组合】
题目大意: 袋子里有N个黑球、M个白球。用1表示取出来的是黑球,0表示取出来的是白球。不放回 的从袋子里取出这N+M个球。求相邻取出的两个球第一个球白球,第二个球是黑球的期望 次数是多少,即出现"01"的期望次数是多少。 思路: 考虑期望可加。第i(1<=i<=N+M)个位置上出现白球的概率为M/(M+N),则i+1个位置上 出现黑球的概率为N/(M+N-1)。因为白球只能在1~M+N-1个位置上出现(后边还有黑球)。 所以出现"01"的次数为(M+n-1)次。则总的期望 = M/(M+N...
分类:其他好文   时间:2015-04-24 21:10:31    阅读次数:156
POJ3687 Labeling Balls (拓扑排序)经典
Labeling Balls Time Limit: 1000MS   Memory Limit: 65536K Total Submissions: 11469   Accepted: 3295 Description Windy has N balls of distinct weights from 1 unit to N un...
分类:编程语言   时间:2015-04-24 19:15:12    阅读次数:176
HDU 5194 DZY Loves Balls(概率)
Problem Description: There are n black balls and m white balls in the big box. Now, DZY starts to randomly pick out the balls one by one. It forms a sequence S. If at the i-th operation,...
分类:其他好文   时间:2015-04-16 09:09:31    阅读次数:174
POJ1703 Find them, Catch them 并查集 好题 有坑点
DescriptionThe police office in Tadu City decides to say ends to the chaos, as launch actions to root up the TWO gangs in the city, Gang Dragon and Ga...
分类:其他好文   时间:2015-04-16 01:07:09    阅读次数:223
484条   上一页 1 ... 32 33 34 35 36 ... 49 下一页
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!