摘要: struct Matrix { int mm[3][3]; Matrix() { memset(mm, 0, sizeof(mm)); } void init(){ for (int i = 0; i >= 1; } return res; } } ; 阅读全文
posted @ 2018-04-10 16:56 luckilzy 阅读(236) 评论(0) 推荐(0) 编辑
摘要: #include #include #include using namespace std; typedef long long ll; const int MAXN = 100009; int n, q; ll sum[MAXN * 4], add[MAXN * 4]; void build(int l, int r, int rt) { add[rt] = 0; if... 阅读全文
posted @ 2018-04-10 16:55 luckilzy 阅读(225) 评论(0) 推荐(0) 编辑
摘要: //http://www.spoj.com/problems/DQUERY/ #include #include #include #include #include using namespace std; const int MAXN = 30009; const int MAXM = 1000009; const int MAXQ = 200009; int n, q, sum,... 阅读全文
posted @ 2018-04-10 16:53 luckilzy 阅读(352) 评论(0) 推荐(0) 编辑