摘要: 1 // 结果超过了long long,到32就超了 2 #include <iostream> 3 #include <cstring> 4 using namespace std; 5 long long fun(int a,int b) 6 { 7 //if(0==b) 8 //return 1; 9 if(1==b)10 return a;11 //本以为会因尽快结束上城循环而加快速度,,谁知执行到return直接跳出函数 12 long long temp;13 temp = fun(a,b/2);14 ... 阅读全文
posted @ 2012-08-20 20:05 加拿大小哥哥 阅读(306) 评论(0) 推荐(0)
摘要: Catch That CowTime Limit: 2000MSMemory Limit: 65536KTotal Submissions: 31637Accepted: 9740DescriptionFarmer John has been informed of the location of a fugitive cow and wants to catch her immediately. He starts at a point N (0 ≤ N ≤ 100,000) on a number line and the cow is at a point K (0 ≤ K ≤ 100, 阅读全文
posted @ 2012-08-20 17:47 加拿大小哥哥 阅读(226) 评论(0) 推荐(1)
摘要: Hat’s WordsTime Limit: 2000/1000 MS (Java/Others)Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 3779Accepted Submission(s): 1432Problem DescriptionA hat’s word is a word in the dictionary that is the concatenation of exactly two other words in the dictionary.You are to find all the ha 阅读全文
posted @ 2012-08-20 11:56 加拿大小哥哥 阅读(323) 评论(0) 推荐(0)