Accepted

/in/foo.cc: In function 'int main()':
/in/foo.cc:13:42: warning: iteration 100000 invokes undefined behavior [-Waggressive-loop-optimizations]
   13 |     for(int i = 1; i <= 100001; i++)b[i] = false;
      |                                     ~~~~~^~~~~~~
/in/foo.cc:13:22: note: within this loop
   13 |     for(int i = 1; i <= 100001; i++)b[i] = false;
      |                    ~~^~~~~~~~~
/in/foo.cc:13:42: warning: 'void* __builtin_memset(void*, int, long unsigned int)' forming offset 100001 is out of the bounds [0, 100001] of object 'b' with type 'bool [100001]' [-Warray-bounds]
   13 |     for(int i = 1; i <= 100001; i++)b[i] = false;
      |                                     ~~~~~^~~~~~~
/in/foo.cc:4:6: note: 'b' declared here
    4 | bool b[100001];
      |      ^
# 状态 耗时 内存占用
#1 Accepted 2ms 644.0 KiB
#2 Accepted 2ms 656.0 KiB
#3 Accepted 2ms 496.0 KiB
#4 Accepted 2ms 656.0 KiB
#5 Accepted 1ms 580.0 KiB

信息

递交者
类型
递交
题目
P1113 s-0-1班级活动之选人
语言
C++
递交时间
2025-03-04 21:51:49
评测时间
2025-03-04 21:51:49
评测机
分数
100
总耗时
12ms
峰值内存
656.0 KiB