symons

___________每一天都是幸福的!!

  博客园  ::  :: 新随笔  ::  :: 订阅 订阅  :: 管理

2013年3月22日

摘要: 模拟,下楼梯不用停。 1 #include <iostream> 2 #include <stdio.h> 3 #include <cmath> 4 #include <string.h> 5 using namespace std; 6 int step[100+10]; 7 int main() 8 { 9 int c;10 int n,i,j,cnt,maxstep;11 int temp;12 while(~scanf("%d",&c))13 {14 while(c--)15 {16 sca... 阅读全文
posted @ 2013-03-22 19:07 symons 阅读(292) 评论(0) 推荐(0)

摘要: 这题是完全背包。我没有优化。 1 #include <iostream> 2 #include <stdio.h> 3 #include <string.h> 4 #include <string.h> 5 #include <cmath> 6 #define maxn 100+10 7 #define maxC 100000+10 8 using namespace std; 9 int f[maxC];10 int c[maxn];11 int v[maxn];12 int main()13 {14 int n,i,j;15 in 阅读全文
posted @ 2013-03-22 18:53 symons 阅读(499) 评论(0) 推荐(0)

摘要: 听说腾讯的编程马拉松启动了,然后我一直准备报名,然后不知道为啥等我报名那一天就没有位置了...无奈了,校赛我也是昨天刚报上名。我在想什么呢?!在HDU上找题目做来看看。这题就是模拟了。注意时间循环的时候是for(i=beign;i<end;++i)这块一定是i<end,不然会出错的。 1 #include <iostream> 2 #include <stdio.h> 3 #include <string.h> 4 #define maxn 24*60+100 5 using namespace std; 6 bool daytime[maxn] 阅读全文
posted @ 2013-03-22 18:34 symons 阅读(301) 评论(0) 推荐(0)

摘要: 近期刷题列表,列表转自大牛 初期:一.基本算法:(1)枚举. (poj1753,poj2965) ★(2)贪心(poj1328,poj2109,poj2586) ★(3)递归和分治法.(4)递推.(5)构造法.(poj3295)(6)模拟法.(poj1068★,poj2632★,poj1573★,p 阅读全文
posted @ 2013-03-22 12:53 symons 阅读(497) 评论(0) 推荐(0)