2015年4月9日

【邻接表字符串Hash】【HDU1800】Flying to the Mars

摘要: 题意: 给你N个数字,带前导0,问出现最多的数字个数 思路: 读入,清楚前导0,Hash。 用邻接表字符串Hash有一下几点注意 string,不要memset,否则地址也没了,涉及到stl的东西,少用memset,类似还有vector; 用 assign截断字符串也是很黄很暴力的直... 阅读全文

posted @ 2015-04-09 15:18 DDUPzy 阅读(181) 评论(0) 推荐(0) 编辑

【巧妙思维】【4-6】Problem F

摘要: 题意:有n个正方体,边长为A[i] 当A[k]-A[p]#include #include #include #include #include #include #include #include #define oo 0x13131313using namespace std;const i... 阅读全文

posted @ 2015-04-09 10:45 DDUPzy 阅读(113) 评论(0) 推荐(0) 编辑

【线段树】【4-6组队赛】Problem H

摘要: Problem Description #include #include using namespace std; int n,a[110000],b[110000],c[110000],d[110000]; int main() { while(cin>>n) ... 阅读全文

posted @ 2015-04-09 10:26 DDUPzy 阅读(131) 评论(0) 推荐(0) 编辑

导航