Main.cc: In function 'int main()': Main.cc:10:19: warning: comparison with string literal results in unspecified behaviour [-Waddress] if(s1[i]==" "){ ^ Main.cc:10:19: error: ISO C++ forbids comparison between pointer and integer [-fpermissive] Main.cc:12:15: error: expected primary-expression before '=' token if(i!==n-1) cout<","; ^