bridges.cpp: In function 'int main()':
bridges.cpp:25:10: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
25 | scanf("%d %d", &n, &m);
| ~~~~~^~~~~~~~~~~~~~~~~
bridges.cpp:30:14: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
30 | scanf("%d %d %d", &u,&v,&d);
| ~~~~~^~~~~~~~~~~~~~~~~~~~~~
bridges.cpp:34:17: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
34 | int q; scanf("%d", &q);
| ~~~~~^~~~~~~~~~
bridges.cpp:36:22: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
36 | int tp; scanf("%d", &tp);
| ~~~~~^~~~~~~~~~~
bridges.cpp:37:24: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
37 | int x, w; scanf("%d%d", &x, &w);
| ~~~~~^~~~~~~~~~~~~~~~