/in/foo.cc: In function 'void SGT::Build(int, int, int)':
/in/foo.cc:47:20: warning: suggest parentheses around '+' inside '>>' [-Wparentheses]
#define mid (l + r >> 1)
~~^~~
/in/foo.cc:48:27: note: in expansion of macro 'mid'
#define lson x << 1,l,mid
^~~
/in/foo.cc:60:20: note: in expansion of macro 'lson'
else Build(lson),Build(rson),Upd(x);
^~~~
/in/foo.cc:47:20: warning: suggest parentheses around '+' inside '>>' [-Wparentheses]
#define mid (l + r >> 1)
~~^~~
/in/foo.cc:49:29: note: in expansion of macro 'mid'
#define rson x << 1 | 1,mid + 1,r
^~~
/in/foo.cc:60:32: note: in expansion of macro 'rson'
else Build(lson),Build(rson),Upd(x);
^~~~
/in/foo.cc: In function 'void SGT::Modify(int, int, int)':
/in/foo.cc:47:20: warning: suggest parentheses around '+' inside '>>' [-Wparentheses]
#define mid (l + r >> 1)
~~^~~
/in/foo.cc:48:27: note: in expansion of macro 'mid'
#define lson x << 1,l,mid
^~~
/in/foo.cc:66:22: note: in expansion of macro 'lson'
Dw(x),Modify(lson),Modify(rson),Upd(x);
^~~~
/in/foo.cc:47:20: warning: suggest parentheses around '+' inside '>>' [-Wparentheses]
#define mid (l + r >> 1)
~~^~~
/in/foo.cc:49:29: note: in expansion of macro 'mid'
#define rson x << 1 | 1,mid + 1,r
^~~
/in/foo.cc:66:35: note: in expansion of macro 'rson'
Dw(x),Modify(lson),Modify(rson),Upd(x);
^~~~
/in/foo.cc: In function 'int SGT::Qry(int, int, int)':
/in/foo.cc:47:20: warning: suggest parentheses around '+' inside '>>' [-Wparentheses]
#define mid (l + r >> 1)
~~^~~
/in/foo.cc:48:27: note: in expansion of macro 'mid'
#define lson x << 1,l,mid
^~~
/in/foo.cc:73:30: note: in expansion of macro 'lson'
return Dw(x),max(Qry(lson),Qry(rson));
^~~~
/in/foo.cc:47:20: warning: suggest parentheses around '+' inside '>>' [-Wparentheses]
#define mid (l + r >> 1)
~~^~~
/in/foo.cc:49:29: note: in expansion of macro 'mid'
#define rson x << 1 | 1,mid + 1,r
^~~
/in/foo.cc:73:40: note: in expansion of macro 'rson'
return Dw(x),max(Qry(lson),Qry(rson));
^~~~
/in/foo.cc: In function 'int main()':
/in/foo.cc:122:145: warning: too many arguments for format [-Wformat-extra-args]
else if(op == 2)scanf("%d%d",&x,&y),z = LCA(x,y),printf("%d\n",SGT::Q(st[x],st[x]) + SGT::Q(st[y],st[y]) - 2 * SGT::Q(st[z],st[z]) + 1,z);
^