Main.cc: In function ‘int main()’: Main.cc:7:9: error: expected ‘)’ before ‘!’ token while(n!-1){ ^ Main.cc:7:12: error: expected ‘;’ before ‘)’ token while(n!-1){ ^ Main.cc:11:2: warning: statement has no effect [-Wunused-value] } ^ Main.cc:12:2: error: ‘else’ without a previous ‘if’ else if(n%2==1){ ^~~~