foo.cc: In function 'int main()':
foo.cc:13:13: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
for (;i < sentence.length();++i)
~~^~~~~~~~~~~~~~~~~~~
foo.cc:15:22: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
for (j = 0;j < word.length();++j)
~~^~~~~~~~~~~~~~~
foo.cc:20:15: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
if (j == word.length() &&( i+j == sentence.length()||sentence[i + j] == ' ' ) )
~~^~~~~~~~~~~~~~~~
foo.cc:20:40: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
if (j == word.length() &&( i+j == sentence.length()||sentence[i + j] == ' ' ) )
~~~~^~~~~~~~~~~~~~~~~~~~
[Hydro](https://hydro.ac)提供评测服务