码迷,mamicode.com
首页 >  
搜索关键字:farmer john wants th    ( 8242个结果
TOJ 4077 Brother Kai wants to know the subdirectory 模拟
http://acm.tju.edu.cn/toj/showp.php?pid=4077前三发各种跪,重写了一遍才过,也不明白原因,感到水平拙计。因为不同文件夹下可能有相同名字的子文件夹,所以map的key值需要再记录一下上级文件夹。 1 #include 2 #include 3 #include...
分类:其他好文   时间:2014-07-29 13:57:58    阅读次数:198
POJ 3280 Cheapest Palindrome (DP)
?? Description Keeping track of all the cows can be a tricky task so Farmer John has installed a system to automate it. He has installed on each cow an electronic ID tag that the system will read ...
分类:其他好文   时间:2014-07-29 13:22:46    阅读次数:212
【HackerRank】Service Lane
Calvin is driving his favorite vehicle on the 101 freeway. He notices that the check engine light of his vehicle is on, and he wants to service it imm...
分类:其他好文   时间:2014-07-29 12:37:16    阅读次数:250
poj 3254 Corn Fields
http://poj.org/problem?id=3254Corn FieldsTime Limit:2000MSMemory Limit:65536KTotal Submissions:7113Accepted:3778DescriptionFarmer John has purchased a...
分类:其他好文   时间:2014-07-29 10:40:46    阅读次数:288
spin.js使用
spin.js,ruby上使用例子<divid="spinBody"> <div> <%form_tag"/login",:id=>"login_form"do-%> <tablewidth="100%"cellpadding="3"style="margin-top:15px;"> <tr> <thstyle="width:80px;"><%=t"a.loginid"%></th> <td..
分类:Web程序   时间:2014-07-28 16:47:24    阅读次数:294
hdu 1907 John
取火柴的游戏 题目1:今有若干堆火柴,两人依次从中拿取,规定每次只能从一堆中取若干根,  可将一堆全取走,但不可不取,最后取完者为胜,求必胜的方法。    若sum=0;则先取者输,后取者胜;   若sum=!0,则先取者使其变成奇异状态,先取者胜  即谁先面临奇异状态谁输; 题目2:今有若干堆火柴,两人依次从中拿取,规定每次只能从一堆中取若干根,  可将一堆全取走,但不可不取,...
分类:其他好文   时间:2014-07-28 16:30:13    阅读次数:240
HDU-4879-ZCC loves march(map+set+并查集)
Description On a m*m land stationed n troops, numbered from 1 to n. The i-th troop's position can be described by two numbers (xi,yi) (1 Then there are t minutes, in each minute one of the followi...
分类:其他好文   时间:2014-07-28 16:25:13    阅读次数:356
POJ 1837 Balance (DP)
Description Gigel has a strange "balance" and he wants to poise it. Actually, the device is different from any other ordinary balance. It orders two arms of negligible weight and each arm's length...
分类:其他好文   时间:2014-07-28 16:14:46    阅读次数:244
POJ-2104-K-th Number(函数式线段树)
Description You are working for Macrohard company in data structures department. After failing your previous task about key insertion you were asked to write a new data structure that would be able...
分类:其他好文   时间:2014-07-28 16:14:11    阅读次数:257
POJ 2104 K-th Number
静态区间第K大,主席树写法。 主席树第一题,如果对整段区间建线段树可以求1~n范围内的第K大,要想求任意区间内的第K大需要建1~i 的n棵线段树。求某一段的时候区间相减就可以了。但是这样空间消耗太大所以要尽量利用以前的节点。注意到1~i的线段树和i~i+1的线段树只某一条链上的值不同,所以我们只要建出这一条链就可以了,剩下的节点和1~i+1的线段树是一样的,我们直接把节点指过去。 T[ ......
分类:其他好文   时间:2014-07-28 15:56:43    阅读次数:270
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!