2012年7月30日

摘要: hdu1166: http://acm.hdu.edu.cn/showproblem.php?pid=1166题意:给出k个正整数,第i个正整数ai代表第i个工兵营地里开始时有ai个人,接下来有一些命令(增加、减少、查询、结束),输出每次查询结果。解法:线段树code:#include<iostream>#include<cstdio>#include<cstdlib>#include<cstring>#include<algorithm>using namespace std;const int inf=1<<29;st 阅读全文
posted @ 2012-07-30 16:56 acmer-jun 阅读(161) 评论(0) 推荐(0) 编辑

导航