stones.cpp: In function 'int main()':
stones.cpp:17:26: error: 'M' was not declared in this scope
17 | if(n==2){cout<<m<<endl;M=m;while(m--)cout<<'-';cout<<'\n';m=M;while(m--)cout<<'-';cout<<'\n';continue;}
| ^
stones.cpp:19:28: error: 'M' was not declared in this scope
19 | if(n==3){cout<<m+1<<endl;M=m;while(m--)cout<<'-';cout<<'\n';m=M;while(m--)cout<<'-';cout<<'\n';m=M;while(m--)cout<<'+';cout<<'\n';continue;}
| ^
stones.cpp:21:28: error: 'M' was not declared in this scope
21 | if(n==4){cout<<m+1<<endl;M=m;while(m--)cout<<'-';cout<<'\n';m=M;while(m--)cout<<'-';cout<<'\n';m=M;while(m--)cout<<'-';cout<<'\n';m=M;while(m--)cout<<'+';cout<<'\n';continue;}
| ^
stones.cpp:34:4: warning: this 'for' clause does not guard... [-Wmisleading-indentation]
34 | for (int i=0; i<m-1; i++)x[i]='-'; x[m-1]='+';
| ^~~
stones.cpp:34:39: note: ...this statement, but the latter is misleadingly indented as if it were guarded by the 'for'
34 | for (int i=0; i<m-1; i++)x[i]='-'; x[m-1]='+';
| ^
stones.cpp:43:5: warning: suggest explicit braces to avoid ambiguous 'else' [-Wdangling-else]
43 | if(n%2==0&&m%2==0)if(n<m)n--,o=1; else m--,u=1;
| ^