上一页 1 ··· 90 91 92 93 94 95 96 97 98 ··· 119 下一页
摘要: 小希的迷宫Time Limit: 2000/1000 MS (Java/Others)Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 14515Accepted Submission(s): 4414Problem Description上次Gardon的迷宫城堡小希玩了很久(见Problem B),现在她也想设计一个迷宫让Gardon来走。但是她设计迷宫的思路不一样,首先她认为所有的通道都应该是双向连通的,就是说如果有一个通道连通了房间A和B,那么既可以通过它从房间A走到房间B,也可以通过它从房间B走到房间A,为了提 阅读全文
posted @ 2012-08-16 16:34 加拿大小哥哥 阅读(260) 评论(0) 推荐(0)
摘要: 2723:不吉利日期时间限制:1000ms内存限制:65536kB描述在国外,每月的13号和每周的星期5都是不吉利的。特别是当13号那天恰好是星期5时,更不吉利。已知某年的一月一日是星期w,并且这一年一定不是闰年,求出这一年所有13号那天是星期5的月份,按从小到大的顺序输出月份数字。(w=1..7)输入输入有一行,即一月一日星期几(w)。(1#include #include using namespace std;int ans[12];int month[12] = {31,28,31,30,31,30,31,31,30,31,30,31};int fun(int num){ int... 阅读全文
posted @ 2012-08-16 15:20 加拿大小哥哥 阅读(488) 评论(0) 推荐(0)
摘要: 2712:细菌繁殖Time Limit:1000msMemory Limit:65536kBDescription一种细菌的繁殖速度是每天成倍增长。例如:第一天有10个,第二天就变成20个,第三天变成40个,第四天变成80个,……。现在给出第一天的日期和细菌数目,要你写程序求出到某一天的时候,细菌的数目。Input第一行有一个整数n,表示测试数据的数目。其后n行每行有5个整数,整数之间用一个空格隔开。第一个数表示第一天的月份,第二个数表示第一天的日期,第三个数表示第一天细菌的数目,第四个数表示要求的那一天的月份,第五个数表示要求的那一天的日期。已知第一天和要求的一天在同一年并且该年不是闰年,要 阅读全文
posted @ 2012-08-16 13:45 加拿大小哥哥 阅读(373) 评论(0) 推荐(0)
摘要: 2792:集合加法ViewSubmitStatisticsClarifyTime Limit:3000msMemory Limit:65536kBDescription给出2个正整数集合A = {pi | 1 #include using namespace std;int s1[10001],s2[10002];int main(){ int i,j,k,T; cin>>T; while(T--) { int ans = 0; memset(s1,0,sizeof(s1)); memset(s2,0,sizeof(s2)); ... 阅读全文
posted @ 2012-08-16 12:52 加拿大小哥哥 阅读(260) 评论(0) 推荐(0)
摘要: 2755:神奇的口袋Time Limit:10000msMemory Limit:65536kBDescription有一个神奇的口袋,总的容积是40,用这个口袋可以变出一些物品,这些物品的总体积必须是40。John现在有n个想要得到的物品,每个物品的体积分别是a1,a2……an。John可以从这些... 阅读全文
posted @ 2012-08-16 12:39 加拿大小哥哥 阅读(262) 评论(0) 推荐(1)
摘要: 放苹果Time Limit: 1000MSMemory Limit: 10000KTotal Submissions: 21050Accepted: 13423Description把M个同样的苹果放在N个同样的盘子里,允许有的盘子空着不放,问共有多少种不同的分法?(用K表示)5,1,1和1,5,1... 阅读全文
posted @ 2012-08-16 11:07 加拿大小哥哥 阅读(305) 评论(0) 推荐(0)
摘要: Red and BlackTime Limit: 1000MSMemory Limit: 30000KTotal Submissions: 17061Accepted: 8996DescriptionThere is a rectangular room, covered with square tiles. Each tile is colored either red or black. A man is standing on a black tile. From a tile, he can move to one of four adjacent tiles. But he can& 阅读全文
posted @ 2012-08-15 23:48 加拿大小哥哥 阅读(731) 评论(0) 推荐(0)
摘要: 1923. Tanning SalonTime Limit: 1.0 Seconds Memory Limit: 65536KTotal Runs: 924 Accepted Runs: 556Tan Your Hide, Inc., owns several coin-operated tanning salons. Research has shown that if a customer arrives and there are no beds available, the customer will turn around and leave, thus costing the c. 阅读全文
posted @ 2012-08-15 21:25 加拿大小哥哥 阅读(388) 评论(0) 推荐(0)
摘要: 1601. Box of BricksTime Limit: 1.0 Seconds Memory Limit: 65536KTotal Runs: 5007 Accepted Runs: 1950Little Bob likes playing with his box of bricks. He puts the bricks one upon another and builds stacks of different height. "Look, I've built a wall!", he tells his older sister Alice. &q 阅读全文
posted @ 2012-08-15 19:20 加拿大小哥哥 阅读(234) 评论(0) 推荐(0)
摘要: 1547. To and FroTime Limit: 1.0 Seconds Memory Limit: 65536KTotal Runs: 885 Accepted Runs: 692Mo and Larry have devised a way of encrypting messages. They first decide secretly on the number of columns and write the message (letters only) down the columns, padding with extra random letters so as to. 阅读全文
posted @ 2012-08-15 18:11 加拿大小哥哥 阅读(214) 评论(0) 推荐(0)
上一页 1 ··· 90 91 92 93 94 95 96 97 98 ··· 119 下一页