Problem segmenttree2
User shoryu386
Submission Time 2025-01-03 22:36:44
Score 0
Max Time N/A
Max Memory N/A

Compile Error

segmenttree2.cpp: In function ‘void update(long long int, long long int, long long int)’:
segmenttree2.cpp:9:25: error: ‘N’ was not declared in this scope
9 | for (int tx=x; tx < N; tx += tx&(-tx)) fw[tx] += v, fw2[tx] -= v*(x-1);
| ^
segmenttree2.cpp:10:27: error: ‘N’ was not declared in this scope
10 | for (int ty=y+1; ty < N; ty += ty&(-ty)) fw[ty] -= v, fw2[ty] += v*y;
| ^
segmenttree2.cpp: In function ‘int main()’:
segmenttree2.cpp:25:2: error: ‘node’ was not declared in this scope
25 | node segtree(0, n-1);
| ^~~~