Wrong Answer

In file included from /usr/include/c++/12/istream:39,
                 from /usr/include/c++/12/sstream:38,
                 from /usr/include/c++/12/complex:45,
                 from /usr/include/c++/12/ccomplex:39,
                 from /usr/include/x86_64-linux-gnu/c++/12/bits/stdc++.h:54,
                 from /in/foo.cc:1:
In member function 'std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(long long int) [with _CharT = char; _Traits = std::char_traits<char>]',
    inlined from 'int main()' at /in/foo.cc:50:8:
/usr/include/c++/12/ostream:202:25: warning: 'ans' may be used uninitialized [-Wmaybe-uninitialized]
  202 |       { return _M_insert(__n); }
      |                ~~~~~~~~~^~~~~
/in/foo.cc: In function 'int main()':
/in/foo.cc:46:14: note: 'ans' was declared here
   46 |         ll n,ans;
      |              ^~~
# 状态 耗时 内存占用
#1 Wrong Answer 2ms 484.0 KiB
#2 Wrong Answer 1ms 476.0 KiB
#3 Wrong Answer 1ms 528.0 KiB
#4 Wrong Answer 1ms 476.0 KiB
#5 Wrong Answer 1ms 532.0 KiB

信息

递交者
类型
递交
题目
P2583 累计相加1级2 2023.6
语言
C++
递交时间
2025-10-22 11:57:10
评测时间
2025-10-22 11:57:10
评测机
分数
0
总耗时
9ms
峰值内存
532.0 KiB