foo.cc: In member function 'void tree::build(int, int, int)':
foo.cc:18:21: warning: suggest parentheses around '+' inside '>>' [-Wparentheses]
18 | int mid = L + R >> 1;
| ~~^~~
foo.cc: In member function 'void tree::modify(int, int, int, int)':
foo.cc:28:27: warning: suggest parentheses around '+' inside '>>' [-Wparentheses]
28 | int mid = nd[p].L + nd[p].R >> 1;
| ~~~~~~~~^~~~~~~~~
foo.cc: In member function 'void tree::query(int, int)':
foo.cc:43:27: warning: suggest parentheses around '+' inside '>>' [-Wparentheses]
43 | int mid = nd[p].L + nd[p].R >> 1;
| ~~~~~~~~^~~~~~~~~
foo.cc: In function 'int main()':
foo.cc:63:10: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
63 | scanf("%d %d", &n, &q);
| ~~~~~^~~~~~~~~~~~~~~~~
foo.cc:71:14: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
71 | scanf("%d", &op);
| ~~~~~^~~~~~~~~~~
foo.cc:75:18: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
75 | scanf("%d %d %d", &l, &r, &v);
| ~~~~~^~~~~~~~~~~~~~~~~~~~~~~~
foo.cc:79:18: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
79 | scanf("%d %d", &x, &v);
| ~~~~~^~~~~~~~~~~~~~~~~
foo.cc:85:18: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
85 | scanf("%d", &x);
| ~~~~~^~~~~~~~~~
[Hydro](https://hydro.ac)提供评测服务