Main.cc: In function ‘int main()’:
Main.cc:7:2: warning: this ‘while’ clause does not guard... [-Wmisleading-indentation]
while(ch[i])
^~~~~
Main.cc:8:14: note: ...this statement, but the latter is misleadingly indented as if it were guarded by the ‘while’
be=ch[i-1];af=ch[i+1];f=ch[i];
^~
Main.cc:9:29: warning: suggest parentheses around ‘&&’ within ‘||’ [-Wparentheses]
if(f=='-'&&af>be&&(be>='0'&&af<='9'||be>='a'&&af<='z')){
~~~~~~~^~~~~~~~~
Main.cc: At global scope:
Main.cc:22:2: error: expected unqualified-id before ‘return’
return 0;
^~~~~~
Main.cc:23:1: error: expected declaration before ‘}’ token
}
^
Main.cc: In function ‘int main()’:
Main.cc:6:7: warning: ignoring return value of ‘int scanf(const char*, ...)’, declared with attribute warn_unused_result [-Wunused-result]
scanf("%d%d%d%s",&p1,&p2,&p3,ch);
~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~