- 博客(8)
- 收藏
- 关注
原创 POJ 2828 Buy Tickets 线段树
#include#include#includeusing namespace std;#define lson l,m,rt<<1#define rson m+1,r,rt<<1|1#define mid (r+l)>>1const int maxn=200300;int node[maxn<<2],a[maxn],b[maxn],ans[maxn];void build(in
2014-06-28 15:53:51 773
原创 POJ 2528 Mayor's posters 离散化线段树
/******************************************离散过程(1-8) (1-3) (6-8)出现了1 3 6 8 ->1 2 3 4海报即变为(1-4) (1-2) (3-4)******************************************/#include#include#include#include
2014-06-27 21:42:30 1048
原创 HDU 3496 Watch The Movie 二维背包
#include #include struct node{ int v,t;}a[333];int Max(int a,int b) { return a>b?a:b; } int main(){ int n,t,dp[144][1111],i,j,k,m,time; scanf("%d",&t); while(t--){ scanf("%d%d%d",&
2014-06-24 23:01:37 718
原创 HDU 4585 Shaolin STL map 水
#include #include #include #include #include #include #include #include #include #include #include usin
2014-06-24 09:10:53 788
原创 POJ 2777 Count Color 线段树区间更新位运算
C A B C 是更新 A-B段位颜色C;P A B 是查询 A - B 有种多少颜色;因为只有3
2014-06-22 13:27:33 942 2
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人