上一页 1 ··· 36 37 38 39 40 41 42 43 44 ··· 50 下一页
摘要: #include #include #include using namespace std;int main(){map word_count;string word;while(cin>>word){pair::iterator,bool> ret;ret=word_count.insert(make_pair(word,1));if(!ret.second){++ret.first->sec... 阅读全文
posted @ 2013-04-28 06:03 码代码的猿猿 阅读(154) 评论(0) 推荐(0) 编辑
摘要: 枚举在每个湖结束钓鱼的情况,去掉移动的时间。这样在各个湖之间的移动就可以看成瞬移的了,贪心可以很容易的求出最大解。Gone FishingTime Limit : 4000/2000ms (Java/Other) Memory Limit : 65536/32768K (Java/Other)Total Submission(s) : Accepted Submission(s) : P... 阅读全文
posted @ 2013-04-28 00:24 码代码的猿猿 阅读(197) 评论(0) 推荐(0) 编辑
摘要: Gone FishingTime Limit : 4000/2000ms (Java/Other)Memory Limit : 65536/32768K (Java/Other)Total Submission(s) : Accepted Submission(s) :Problem DescriptionJohn is going on a fishing trip. He has h hours available (1 <= h <= 16), and there are n lakes in the area (2 <= n <= 25) all reachab 阅读全文
posted @ 2013-04-27 16:32 码代码的猿猿 阅读(254) 评论(0) 推荐(0) 编辑
摘要: Tian Ji -- The Horse RacingTime Limit : 2000/1000ms (Java/Other) Memory Limit : 65536/32768K (Java/Other)Total Submission(s) : Accepted Submission(s) :Problem DescriptionHere is a famous story in ... 阅读全文
posted @ 2013-04-26 02:12 码代码的猿猿 阅读(240) 评论(0) 推荐(0) 编辑
摘要: 题目意思很难得懂,给N个2次函数,求最大值中的最小值3分法 (用黄金分割比例可以省去一次计算使速度更快)用CIN COUT会超时Error CurvesTime Limit : 4000/2000ms (Java/Other) Memory Limit : 65536/65536K (Java/Other)Total Submission(s) : Accepted Submissio... 阅读全文
posted @ 2013-04-25 05:23 码代码的猿猿 阅读(181) 评论(0) 推荐(0) 编辑
摘要: 题目意思很难得懂,给N个2次函数,求最大值中的最小值3分法 (用黄金分割比例可以省去一次计算使速度更快)用CIN COUT会超时Error CurvesTime Limit : 4000/2000ms (Java/Other)Memory Limit : 65536/65536K (Java/Other)Total Submission(s) : Accepted Submission(s) :Problem DescriptionJosephina is a clever girl and addicted to Machine Learning recently. Shepays muc. 阅读全文
posted @ 2013-04-24 21:27 码代码的猿猿 阅读(228) 评论(0) 推荐(0) 编辑
摘要: 男人8题:第8题二分+贪心判断答案Elevator Stopping PlanTime Limit:1000MSMemory Limit:30000KTotal Submissions:1839Accepted:614DescriptionZSoft Corp. is a software company in GaoKe Hall. And the workers in the hall are very hard-working. But the elevator in that hall always drives them crazy. Why? Because there is on 阅读全文
posted @ 2013-04-24 15:07 码代码的猿猿 阅读(372) 评论(0) 推荐(0) 编辑
摘要: #include #include using namespace std;int is_run(int year){ if(year%100!=0&&year%4==0) return 1; if(year%400==0) return 1; else return 0;}int main(){ int k; cin>>k;... 阅读全文
posted @ 2013-04-24 05:31 码代码的猿猿 阅读(186) 评论(0) 推荐(0) 编辑
摘要: 用字符形式输出数字必WA。#include #include using namespace std;int main(){ int n; string s; cin>>n;for(int i=0;i>s; char c=s[0]; int len=s.length(); for(int j=1;j<=len;j++) { if(s[j]==... 阅读全文
posted @ 2013-04-24 03:59 码代码的猿猿 阅读(106) 评论(0) 推荐(0) 编辑
摘要: 充满各种PE的垃圾题#include using namespace std;int n,m;static int c=0;int round;int main(){cin>>round;for(int l=0;l>n>>m){ if(n==0&&m==0) break; int tot=0; int ans; for(int i=1;i<n;i++) fo... 阅读全文
posted @ 2013-04-24 03:30 码代码的猿猿 阅读(156) 评论(0) 推荐(0) 编辑
上一页 1 ··· 36 37 38 39 40 41 42 43 44 ··· 50 下一页