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:26:14: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
26 | int Q; scanf("%d",&Q);
| ~~~~~^~~~~~~~~
Main.cpp:29:15: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
29 | int q; scanf("%d",&q);
| ~~~~~^~~~~~~~~
Main.cpp:32:20: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
32 | int l,r,m; scanf("%d %d %d",&l,&r,&m);
| ~~~~~^~~~~~~~~~~~~~~~~~~~~
Main.cpp:40:9: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
40 | scanf("%d",&x);
| ~~~~~^~~~~~~~~