telegraph.cpp: In function 'int main()':
telegraph.cpp:30:12: warning: unused variable 'a' [-Wunused-variable]
int q, i, a, b, c, x, y;
^
telegraph.cpp:30:15: warning: unused variable 'b' [-Wunused-variable]
int q, i, a, b, c, x, y;
^
telegraph.cpp:30:18: warning: unused variable 'c' [-Wunused-variable]
int q, i, a, b, c, x, y;
^
telegraph.cpp:30:21: warning: unused variable 'x' [-Wunused-variable]
int q, i, a, b, c, x, y;
^
telegraph.cpp:30:24: warning: unused variable 'y' [-Wunused-variable]
int q, i, a, b, c, x, y;
^
telegraph.cpp: At global scope:
telegraph.cpp:136:2: error: expected unqualified-id before 'return'
return 0;
^~~~~~
telegraph.cpp:137:1: error: expected declaration before '}' token
}
^
telegraph.cpp: In function 'int main()':
telegraph.cpp:32:7: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
scanf("%d%d", &n, &q);
~~~~~^~~~~~~~~~~~~~~~
telegraph.cpp:35:8: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
scanf("%d", A+i);
~~~~~^~~~~~~~~~~