jail.cpp: In function 'int main()':
jail.cpp:22:10: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
22 | scanf("%d", &q);
| ~~~~~^~~~~~~~~~
jail.cpp:24:14: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
24 | scanf("%d", &n);
| ~~~~~^~~~~~~~~~
jail.cpp:25:52: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
25 | for (int i = 0, a, b; i < n - 1; i++) scanf("%d %d", &a, &b);
| ~~~~~^~~~~~~~~~~~~~~~~
jail.cpp:26:14: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
26 | scanf("%d", &m);
| ~~~~~^~~~~~~~~~
jail.cpp:29:18: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
29 | scanf("%d %d", &s, &t);
| ~~~~~^~~~~~~~~~~~~~~~~