plan.cpp: In function 'int main()':
plan.cpp:10:10: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
10 | scanf("%d %d", &n, &m);
| ~~~~~^~~~~~~~~~~~~~~~~
plan.cpp:13:35: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
13 | for (auto &[z, x, y]: u) scanf("%d %d %d", &x, &y, &z), v[x].emplace_back(y, z), v[y].emplace_back(x, z);
| ~~~~~^~~~~~~~~~~~~~~~~~~~~~~~
plan.cpp:14:10: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
14 | scanf("%d", &k);
| ~~~~~^~~~~~~~~~
plan.cpp:17:27: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
17 | for (auto &e: g) scanf("%d", &e), pq.emplace(d[e] = 0, e);
| ~~~~~^~~~~~~~~~
plan.cpp:30:10: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
30 | scanf("%d", &q);
| ~~~~~^~~~~~~~~~
plan.cpp:32:33: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
32 | for (auto &[x, y]: cq) scanf("%d %d", &x, &y);
| ~~~~~^~~~~~~~~~~~~~~~~