Main.cc: In function ‘int ismagic(int*, int, int)’:
Main.cc:13:45: error: a function-definition is not allowed here before ‘{’ token
13 | int findAnyPalindrome(int arr[], int n) {
| ^
Main.cc:28:13: warning: empty parentheses were disambiguated as a function declaration [-Wvexing-parse]
28 | int main() {
| ^~
Main.cc:28:13: note: remove parentheses to default-initialize a variable
28 | int main() {
| ^~
| --
Main.cc:28:13: note: or replace parentheses with braces to value-initialize a variable
Main.cc:28:16: error: a function-definition is not allowed here before ‘{’ token
28 | int main() {
| ^
Main.cc:41:6: error: expected ‘}’ at end of input
41 | }
| ^
Main.cc:3:44: note: to match this ‘{’
3 | int ismagic(int arr[], int start, int end) {
| ^
Main.cc:41:6: warning: control reaches end of non-void function [-Wreturn-type]
41 | }
| ^