/ Vijos /

记录详情

Wrong Answer

foo.cc: In function 'int main()':
foo.cc:9:10: warning: iteration 9998 invokes undefined behavior [-Waggressive-loop-optimizations]
    9 |      a[i]=i-1/i;
      |      ~~~~^~~~~~
foo.cc:8:18: note: within this loop
    8 |     for(int i=2;i<=10000;i++){
      |                 ~^~~~~~~
foo.cc:13:11: warning: iteration 9998 invokes undefined behavior [-Waggressive-loop-optimizations]
   13 |   b[i]=b[i]+a[i-1];
      |        ~~~^
foo.cc:12:15: note: within this loop
   12 |  for(int i=2;i<=10000;i++){
      |              ~^~~~~~~
[Hydro](https://hydro.ac)提供评测服务
# 状态 耗时 内存占用
#1 Wrong Answer Read 6, expect 11. 2ms 512.0 KiB
#2 Wrong Answer Read 10, expect 616. 2ms 512.0 KiB
#3 Wrong Answer Read 17, expect 675214. 2ms 512.0 KiB
#4 Wrong Answer Read 13, expect 12367. 2ms 512.0 KiB
#5 Wrong Answer Read 15, expect 91380. 2ms 512.0 KiB

信息

递交者
类型
递交
题目
P1127 级数求和
语言
C++
递交时间
2022-01-26 11:41:23
评测时间
2022-01-26 11:41:23
评测机
分数
0
总耗时
12ms
峰值内存
512.0 KiB