foo.cc: In function 'int main()':
foo.cc:22:11: warning: comparison of integer expressions of different signedness: 'll' {aka 'long long int'} and 'std::__cxx11::basic_string<char>::size_type' {aka 'long unsigned int'} [-Wsign-compare]
22 | for(i=0;i<s.size();i++)
| ~^~~~~~~~~
foo.cc:27:15: warning: format '%d' expects argument of type 'int', but argument 2 has type 'll' {aka 'long long int'} [-Wformat=]
27 | printf("Sum:%d\n", j);
| ~^ ~
| | |
| int ll {aka long long int}
| %lld
foo.cc:28:17: warning: format '%d' expects argument of type 'int', but argument 2 has type 'll' {aka 'long long int'} [-Wformat=]
28 | printf("Numer:%d\n", k);
| ~^ ~
| | |
| int ll {aka long long int}
| %lld
foo.cc:29:9: warning: too many arguments for format [-Wformat-extra-args]
29 | printf("Factors:", k);
| ^~~~~~~~~~
foo.cc:31:12: warning: format '%d' expects argument of type 'int', but argument 2 has type 'll' {aka 'long long int'} [-Wformat=]
31 | printf("%6d",a[i]);
| ~~^ ~~~~
| | |
| int ll {aka long long int}
| %6lld
正在同步测试数据,请稍后
[Hydro](https://hydro.ac)提供评测服务