ballmachine.cpp: In function 'int main()':
ballmachine.cpp:19:24: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
19 | int n, q, rt; scanf("%d %d", &n, &q); LOG = 32 - __builtin_clz(n);
| ~~~~~^~~~~~~~~~~~~~~~~
ballmachine.cpp:21:14: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
21 | scanf("%d", &u);
| ~~~~~^~~~~~~~~~
ballmachine.cpp:29:14: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
29 | scanf("%d", &op);
| ~~~~~^~~~~~~~~~~
ballmachine.cpp:31:18: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
31 | scanf("%d", &k);
| ~~~~~^~~~~~~~~~
ballmachine.cpp:34:18: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
34 | scanf("%d", &u); --u;
| ~~~~~^~~~~~~~~~
ballmachine.cpp:35:13: warning: 'rt' may be used uninitialized in this function [-Wmaybe-uninitialized]
35 | if(u == rt || sz < SZ[up[u][0]]){ puts("0"); --sz; continue;}
| ^~