foo.cc: In function ‘int main()’:
foo.cc:7:18: warning: comparison of integer expressions of different signedness: ‘int’ and ‘std::__cxx11::basic_string<char>::size_type’ {aka ‘long unsigned int’} [-Wsign-compare]
7 | for(int i=0;i<s.size();i++)
| ~^~~~~~~~~
foo.cc:9:9: warning: this ‘if’ clause does not guard... [-Wmisleading-indentation]
9 | if(s[i-1]==' '&&s[i]==' ')
| ^~
foo.cc:11:17: note: ...this statement, but the latter is misleadingly indented as if it were guarded by the ‘if’
11 | if(s[i]==' ')
| ^~
foo.cc:18:21: warning: comparison of integer expressions of different signedness: ‘int’ and ‘std::__cxx11::basic_string<char>::size_type’ {aka ‘long unsigned int’} [-Wsign-compare]
18 | if(i==s.size()-1)
| ~^~~~~~~~~~~~