10 2012 档案

摘要:Curling 2.0Time Limit: 1000MSMemory Limit: 65536KTotal Submissions: 7356Accepted: 3069DescriptionOn Planet MM-21, after their Olympic games this year, curling is getting popular. But the rules are somewhat different from ours. The game is played on an ice game board on which a square mesh is marked. 阅读全文
posted @ 2012-10-29 19:46 M_cag 阅读(189) 评论(0) 推荐(0)
摘要:A Knight's JourneyTime Limit: 1000MSMemory Limit: 65536KTotal Submissions: 22306Accepted: 7546DescriptionBackground The knight is getting bored of seeing the same black and white squares again and again and has decided to make a journey around the world. Whenever a knight moves, it is two square 阅读全文
posted @ 2012-10-28 20:46 M_cag 阅读(231) 评论(0) 推荐(0)
摘要:连连看Time Limit: 20000/10000 MS (Java/Others)Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 10550Accepted Submission(s): 2805Problem Description“连连看”相信很多人都玩过。没玩过也没关系,下面我给大家介绍一下游戏规则:在一个棋盘中,放了很多的棋子。如果某两个相同的棋子,可以通过一条线连起来(这条线不能经过其它棋子),而且线的转折次数不超过两次,那么这两个棋子就可以在棋盘上消去。不好意思,由于我以前没有玩过连连看,咨询了同学的意 阅读全文
posted @ 2012-10-17 21:08 M_cag 阅读(342) 评论(0) 推荐(0)
摘要:Max SumTime Limit: 2000/1000 MS (Java/Others)Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 87019Accepted Submission(s): 20165Problem DescriptionGiven a sequence a[1],a[2],a[3]......a[n], your job is to calculate the max sum of a sub-sequence. For example, given (6,-1,5,4,-7), the... 阅读全文
posted @ 2012-10-14 21:31 M_cag 阅读(174) 评论(0) 推荐(0)
摘要:#include<stdio.h>#include<math.h>#define PI 3.1415926535898#define e 2.7182818284590 int main(){int t,n;double ans;scanf("%d",&t);while(t--){scanf("%d",&n);ans=log10(sqrt(2*PI*n))+n*log10(n/e);printf("%.0lf\n",ceil(ans));}return 0;} 阅读全文
posted @ 2012-10-09 21:09 M_cag 阅读(96) 评论(0) 推荐(0)