摘要: 1 /* 2 HDU6010 Daylight Saving Time 3 http://acm.hdu.edu.cn/showproblem.php?pid=6010 4 模拟 5 题意:算当前时间是否是夏令时 6 7 */ 8 #include 9 #include 10 using namespace std; 11 //#defin... 阅读全文
posted @ 2017-03-24 11:57 BBBob 阅读(514) 评论(0) 推荐(0) 编辑
摘要: 1 /* 2 HDU5926 Mr. Frog’s Game 3 http://acm.hdu.edu.cn/showproblem.php?pid=5926 4 杂题水题 5 * 6 */ 7 #include 8 #include 9 using namespace std; 10 const int Nmax=35; 11 int t,n,m; 12 int... 阅读全文
posted @ 2017-03-24 11:54 BBBob 阅读(180) 评论(0) 推荐(0) 编辑
摘要: 1 /* 2 HDU5924 Mr. Frog’s Problem 3 http://acm.hdu.edu.cn/showproblem.php?pid=5924 4 数论 5 * 6 */ 7 #include 8 int main() 9 { 10 long long a,b; 11 int t; 12 scanf("%d",&t); ... 阅读全文
posted @ 2017-03-24 11:52 BBBob 阅读(228) 评论(0) 推荐(0) 编辑
摘要: 1 /* 2 HDU5979 Convex 3 http://acm.hdu.edu.cn/showproblem.php?pid=5979 4 计算几何 三角形面积公式 5 * 6 * 7 */ 8 #include 9 #include 10 #include 11 using namespace std; 12 const double Pi=acos(... 阅读全文
posted @ 2017-03-24 11:47 BBBob 阅读(161) 评论(0) 推荐(0) 编辑
摘要: 1 /* 2 HDU5976 Detachment 3 http://acm.hdu.edu.cn/showproblem.php?pid=5976 4 数论 等差数列 5 * 6 * 7 */ 8 #include 9 #include 10 #include 11 using namespace std; 12 const int mod=10000000... 阅读全文
posted @ 2017-03-24 11:45 BBBob 阅读(285) 评论(0) 推荐(0) 编辑
摘要: 1 /* 2 HDU3236 Gift Hunting 3 http://acm.hdu.edu.cn/showproblem.php?pid=3236 4 dp 滚动数组 5 * 6 * 7 */ 8 #include 9 #include 10 using namespace std; 11 const int Nmax=305; 12 const int ... 阅读全文
posted @ 2017-03-24 11:39 BBBob 阅读(161) 评论(0) 推荐(0) 编辑
摘要: 1 /* 2 POJ1061 青蛙的约会 3 http://poj.org/problem?id=1061 4 扩展欧几里得 5 6 原题为求t使得,存在l满足 7 (x+mt)-(y+nt)=cl 8 即求 9 cl+(n-m)t=x-y 10 * 11 * 12 * 13 */ 14 15 #include 16 #includ... 阅读全文
posted @ 2017-03-23 20:27 BBBob 阅读(154) 评论(0) 推荐(0) 编辑
摘要: 1 /* 2 UVA10200 Prime Time 3 https://uva.onlinejudge.org/index.php?option=com_onlinejudge&Itemid=8&page=show_problem&problem=1141 4 素数 概率论 暴力 5 6 输出的时候加1e-5到1e-14都能过,不加就wa,不是很懂 7 * 8 ... 阅读全文
posted @ 2017-03-17 17:39 BBBob 阅读(184) 评论(0) 推荐(0) 编辑
摘要: 1 /* 2 POJ2960 S-Nim 3 http://poj.org/problem?id=2960 4 博弈论 SG函数 5 * 6 */ 7 8 #include 9 #include 10 #include 11 using namespace std; 12 const int Nmax=10005; 13 //s[]:可以取走的石子个数 1... 阅读全文
posted @ 2017-03-17 11:58 BBBob 阅读(141) 评论(0) 推荐(0) 编辑
摘要: 1 /* 2 HDU1850 Being a Good Boy in Spring Festival 3 http://acm.hdu.edu.cn/showproblem.php?pid=1850 4 博弈论 尼姆博弈 5 6 7 尼姆博弈:异或和为0则先手必败,否则先手必胜 8 * 9 * 10 */ 11 #include 12 #include 1... 阅读全文
posted @ 2017-03-16 19:43 BBBob 阅读(135) 评论(0) 推荐(0) 编辑