garage.cpp: In function 'int main()':
garage.cpp:5:16: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
5 | int n,m; scanf("%d %d",&n,&m);
| ~~~~~^~~~~~~~~~~~~~~
garage.cpp:7:29: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
7 | for(int i=1;i<=n;i++) scanf("%d",&r[i]);
| ~~~~~^~~~~~~~~~~~
garage.cpp:9:29: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
9 | for(int i=1;i<=m;i++) scanf("%d",&h[i]);
| ~~~~~^~~~~~~~~~~~
garage.cpp:18:17: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
18 | int act; scanf("%d",&act);
| ~~~~~^~~~~~~~~~~