bridges.cpp: In function 'int main()':
bridges.cpp:22:10: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
22 | scanf("%d %d", &n, &m);
| ~~~~~^~~~~~~~~~~~~~~~~
bridges.cpp:24:27: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
24 | int a, b, c; scanf("%d %d %d", &a, &b, &c); --a, --b;
| ~~~~~^~~~~~~~~~~~~~~~~~~~~~~~
bridges.cpp:28:10: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
28 | scanf("%d", &q);
| ~~~~~^~~~~~~~~~
bridges.cpp:30:27: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
30 | int a, b, c; scanf("%d %d %d", &a, &b, &c), --b;
| ~~~~~^~~~~~~~~~~~~~~~~~~~~~~~