Main.cpp: In function 'int main()':
Main.cpp:21:16: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
21 | int N,K; scanf("%d %d",&N,&K);
| ~~~~~^~~~~~~~~~~~~~~
Main.cpp:23:31: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
23 | for(int i=1; i<=N; i++) scanf("%d",&A[i]);
| ~~~~~^~~~~~~~~~~~
Main.cpp:24:14: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
24 | int Q; scanf("%d",&Q);
| ~~~~~^~~~~~~~~
Main.cpp:27:15: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
27 | int q; scanf("%d",&q);
| ~~~~~^~~~~~~~~
Main.cpp:30:20: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
30 | int l,r,m; scanf("%d %d %d",&l,&r,&m);
| ~~~~~^~~~~~~~~~~~~~~~~~~~~
Main.cpp:39:9: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
39 | scanf("%d",&x);
| ~~~~~^~~~~~~~~