Wrong Answer

/in/foo.cc: In function 'int count0(std::__cxx11::string)':
/in/foo.cc:20:15: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
  for(int i=0;i<num.size();i++)
              ~^~~~~~~~~~~
/in/foo.cc: In function 'int count1(std::__cxx11::string)':
/in/foo.cc:28:15: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
  for(int i=0;i<num.size();i++)
              ~^~~~~~~~~~~
/in/foo.cc: In function 'int count0(std::__cxx11::string)':
/in/foo.cc:23:9: warning: 'ret' may be used uninitialized in this function [-Wmaybe-uninitialized]
  return ret;
         ^~~
/in/foo.cc: In function 'int count1(std::__cxx11::string)':
/in/foo.cc:31:9: warning: 'ret' may be used uninitialized in this function [-Wmaybe-uninitialized]
  return ret;
         ^~~
/in/foo.cc: In function 'int main()':
/in/foo.cc:39:3: warning: 'ret' may be used uninitialized in this function [-Wmaybe-uninitialized]
   if(count0(num)<count1(num))
   ^~
/in/foo.cc:39:3: warning: 'ret' may be used uninitialized in this function [-Wmaybe-uninitialized]
# 状态 耗时 内存占用
#1 Wrong Answer 2ms 388.0 KiB

信息

递交者
类型
自测
语言
C++
递交时间
2025-01-22 16:47:24
评测时间
2025-01-22 16:47:24
评测机
分数
0
总耗时
2ms
峰值内存
388.0 KiB