foo.cc: In constructor 'node::node(int, int, int, int)':
foo.cc:39:27: warning: 'node::maxn' will be initialized after [-Wreorder]
39 | int sum,lmax,rmax,maxn;
| ^~~~
foo.cc:39:13: warning: 'int node::sum' [-Wreorder]
39 | int sum,lmax,rmax,maxn;
| ^~~
foo.cc:40:9: warning: when initialized here [-Wreorder]
40 | node(int a = 0,int b = 0,int c = -2000000000,int d = 0):lmax(a),rmax(b),maxn(c),sum(d){}
| ^~~~
In file included from /nix/store/n19qjv3wanlki2nfwzr53mwc4qxk5vhn-gcc/include/c++/11.3.0/bits/char_traits.h:39,
from /nix/store/n19qjv3wanlki2nfwzr53mwc4qxk5vhn-gcc/include/c++/11.3.0/ios:40,
from /nix/store/n19qjv3wanlki2nfwzr53mwc4qxk5vhn-gcc/include/c++/11.3.0/ostream:38,
from /nix/store/n19qjv3wanlki2nfwzr53mwc4qxk5vhn-gcc/include/c++/11.3.0/iostream:39,
from foo.cc:2:
/nix/store/n19qjv3wanlki2nfwzr53mwc4qxk5vhn-gcc/include/c++/11.3.0/bits/stl_algobase.h: In instantiation of 'const _Tp& std::max(const _Tp&, const _Tp&, _Compare) [with _Tp = int; _Compare = int]':
foo.cc:130:14: required from here
/nix/store/n19qjv3wanlki2nfwzr53mwc4qxk5vhn-gcc/include/c++/11.3.0/bits/stl_algobase.h:303:17: error: '__comp' cannot be used as a function
303 | if (__comp(__a, __b))
| ~~~~~~^~~~~~~~~~
[Hydro](https://hydro.ac)提供评测服务