摘要:
Python特殊语法:filter、map、reduce、lambda [转]http://www.cnblogs.com/longdouhzt/archive/2012/05/19/2508844.htmlmap函数用法 1 ls = [1,2,3] 2 rs = map(str, ls) 3 ... 阅读全文
摘要:
setset s;s.insert(x);int x = *(--s.lower_bound(x));vectorint pos = lower_bound(v.begin(), v.end(), x) - v.begin(); 阅读全文
摘要:
开始刷DP 。。【背包问题】2602 Bone Collector 1114 Piggy-Bank 1203 I NEED A OFFER!1171 Big Event in HDU1059 Dividing 2844 Coins 2191 悼念512汶川大地震遇难同胞——珍惜现在,感恩生活21... 阅读全文
摘要:
zoj Tree of Tree 1 /*Author :usedrose */ 2 /*Created Time :2015/7/26 1:06:37*/ 3 /*File Name :2.cpp*/ 4 #include 5 #include 6 #include 7 #include ... 阅读全文
摘要:
Dinic模板 1 int n, m, T; 2 int st, en; 3 4 const int INF=0x3f3f3f3f; 5 const int MAXN = 1122;//点数的最大值 6 const int MAXM = 355555;//边数的最大值 7 8 s... 阅读全文
摘要:
模板 2255 1 /*Author :usedrose */ 2 /*Created Time :2015/8/30 1:20:31*/ 3 /*File Name :2.cpp*/ 4 #pragma comment(linker, "/STACK:1024000000,1024000... 阅读全文
摘要:
【HDU】1384Intervals基础差分约束★1529Cashier Employment 神级差分约束★★★★1531King差分约束★1534Schedule Problem 差分约束输出一组解★3440House Man 比较好的差分约束★★3592World Exhibition 简单★... 阅读全文
摘要:
【HDU】3062Party 1 /*Author :usedrose */ 2 /*Created Time :2015/6/2 11:26:32*/ 3 /*File Name :2.cpp*/ 4 #include 5 #include 6 #include 7 #inc... 阅读全文
摘要:
C.Pashmak and Buses 构造看成k进制的d位数。。 1 n,k,d = map(int, raw_input().split()) 2 if n > k**d: print -1 3 else: 4 ans = [] 5 for i in range(n): 6 ... 阅读全文
摘要:
题解见:http://blog.csdn.net/libin56842/article/details/46650209注意这里的组合数取模~~~ 1 /*Author :usedrose */ 2 /*Created Time :2015/8/7 13:31:44*/ 3 /*File Name... 阅读全文
摘要:
转自http://www.cnblogs.com/keam37/p/4578568.html 1 /*Author :usedrose */ 2 /*Created Time :2015/8/7 12:26:39*/ 3 /*File Name :2.cpp*/ 4 #pragma com... 阅读全文