上一页 1 2 3 4 5 6 7 8 9 ··· 11 下一页

2013年3月26日

SRM 574 DIV2

摘要: 1、目前为止见过的最长的第一道题目了,直接计数就OK了 1 #include <iostream> 2 #include <string> 3 #include <vector> 4 #include <cstdlib> 5 #include <cmath> 6 #include <map> 7 #include <stack> 8 #include <algorithm> 9 #include <list> 10 #include <ctime> 11 #include & 阅读全文

posted @ 2013-03-26 11:00 kakamilan 阅读(199) 评论(0) 推荐(0) 编辑

2013年3月16日

SRM 573 DIV2

摘要: 1、照旧水题~~~,略过2、贪心算法 1 #include <iostream> 2 #include <string> 3 #include <vector> 4 #include <cstdlib> 5 #include <cmath> 6 #include <map> 7 #include <stack> 8 #include <algorithm> 9 #include <list> 10 #include <ctime> 11 #include <set> 阅读全文

posted @ 2013-03-16 12:49 kakamilan 阅读(157) 评论(0) 推荐(0) 编辑

2013年3月10日

TCO 2013 1C

摘要: 1、晚上一点多爬起来太痛苦了,脑子晕乎乎的,第一个都没做出来~~~~ 1 #include <iostream> 2 #include <string> 3 #include <vector> 4 #include <cstdlib> 5 #include <cmath> 6 #include <map> 7 #include <stack> 8 #include <algorithm> 9 #include <list>10 #include <ctime>11 #incl 阅读全文

posted @ 2013-03-10 14:56 kakamilan 阅读(159) 评论(0) 推荐(0) 编辑

2013年2月14日

srm 569 div2

摘要: 1、水题,直接穷举就OK了。 1 #include <iostream> 2 #include <string> 3 #include <vector> 4 #include <cstdlib> 5 #include <cmath> 6 #include <map> 7 #include <stack> 8 #include <algorithm> 9 #include <list>10 #include <ctime>11 #include <set>12 #i 阅读全文

posted @ 2013-02-14 18:25 kakamilan 阅读(192) 评论(0) 推荐(0) 编辑

2012年12月28日

srm 565 div2

摘要: 1、水题,简单的画图,略过。2、用到了贪心算法,需要把当前n个金币可以买到的最强能力保存下来,然后在可以达到终点的路径中取最小的即可。 1 #include <iostream> 2 #include <string> 3 #include <vector> 4 #include <cstdlib> 5 #include <cmath> 6 #include <map> 7 #include <stack> 8 #include <algorithm> 9 #include <list> 阅读全文

posted @ 2012-12-28 14:49 kakamilan 阅读(196) 评论(0) 推荐(0) 编辑

2012年12月15日

SRM 563 DIV1 DIV2

摘要: 2、0-1背包问题,边界问题稍微麻烦一些。 1 #include <iostream> 2 #include <string> 3 #include <vector> 4 #include <cstdlib> 5 #include <map> 6 #include <algorithm> 7 #include <stack> 8 #include <queue> 9 #include <cmath>10 using namespace std;11 int dp[105][105];// 阅读全文

posted @ 2012-12-15 16:16 kakamilan 阅读(190) 评论(0) 推荐(0) 编辑

2012年12月13日

SRM 564 DIV2 DIV1

摘要: 1、只要把重复出现的删掉再判断就OK了。 1 #include <iostream> 2 #include <string> 3 #include <vector> 4 #include <cstdlib> 5 #include <map> 6 #include <algorithm> 7 #include <stack> 8 #include <queue> 9 #include <cmath>10 using namespace std;11 class FauxPalindrome 阅读全文

posted @ 2012-12-13 16:05 kakamilan 阅读(203) 评论(0) 推荐(0) 编辑

2012年12月1日

SRM 562 DIV2

摘要: 1、第一个,水题,直接求最大值即可,略。2、根据题目,clipboard最大的时候是50,则可以得到,当粘贴超过50次以后,每次增长的个数是肯定是固定个数。 写的时候为了保险,把50换到了100多。 1 #include <iostream> 2 #include <string> 3 #include <vector> 4 #include <cstdlib> 5 #include <map> 6 #include <algorithm> 7 #include <stack> 8 #include <q 阅读全文

posted @ 2012-12-01 15:24 kakamilan 阅读(164) 评论(0) 推荐(0) 编辑

2012年11月22日

SRM 561 DIV2 DIV1

摘要: 1、水题,略。2、用到了状态压缩 注释清楚http://blog.csdn.net/hhaile/article/details/8209474#include <iostream>#include <string>#include <vector>#include <cstdlib>#include <map>#include <algorithm>using namespace std;#define INF 999999class ICPCBalloons {public: int minRepaintings(ve 阅读全文

posted @ 2012-11-22 17:04 kakamilan 阅读(284) 评论(0) 推荐(0) 编辑

2012年10月14日

KMP算法

摘要: matrix67大神的算法讲解的太犀利了http://www.matrix67.com/blog/archives/115 1 #include <iostream> 2 #include <string> 3 #include <vector> 4 #include <queue> 5 #include <algorithm> 6 #include <cstdio> 7 #include <list> 8 #include <cstring> 9 using namespace std;10 11 阅读全文

posted @ 2012-10-14 19:24 kakamilan 阅读(209) 评论(0) 推荐(0) 编辑

上一页 1 2 3 4 5 6 7 8 9 ··· 11 下一页

导航