Accepted

/in/foo.cc: In function 'void shai()':
/in/foo.cc:9:50: warning: iteration 1000004 invokes undefined behavior [-Waggressive-loop-optimizations]
    9 |   for(int i=1;i<=1000005;i++) b[i]=b[i-1]+int(a[i]);
      |                                               ~~~^
/in/foo.cc:9:16: note: within this loop
    9 |   for(int i=1;i<=1000005;i++) b[i]=b[i-1]+int(a[i]);
      |               ~^~~~~~~~~
# 状态 耗时 内存占用
#1 Accepted 7ms 5.129 MiB
#2 Accepted 122ms 5.336 MiB
#3 Accepted 8ms 5.227 MiB
#4 Accepted 8ms 5.188 MiB
#5 Accepted 9ms 5.176 MiB
#6 Accepted 9ms 5.324 MiB
#7 Accepted 43ms 5.32 MiB
#8 Accepted 67ms 5.324 MiB
#9 Accepted 92ms 5.32 MiB
#10 Accepted 121ms 5.344 MiB

信息

递交者
类型
递交
题目
P1007 统计质数
语言
C++
递交时间
2026-03-08 13:51:09
评测时间
2026-03-08 13:51:09
评测机
分数
100
总耗时
489ms
峰值内存
5.344 MiB