记录详情

Wrong Answer

foo.cc: In function 'int main()':
foo.cc:68:16: warning: iteration 5000 invokes undefined behavior [-Waggressive-loop-optimizations]
   68 |         head[i]=-1;
      |         ~~~~~~~^~~
foo.cc:67:20: note: within this loop
   67 |     for (int i=1; i<=5001; i++) {
      |                   ~^~~~~~
foo.cc:68:16: warning: 'void* __builtin_memset(void*, int, long unsigned int)' forming offset [40008, 40015] is out of the bounds [0, 40008] of object 'head' with type 'long long int [5001]' [-Warray-bounds]
   68 |         head[i]=-1;
      |         ~~~~~~~^~~
foo.cc:20:5: note: 'head' declared here
   20 | int head[5001];
      |     ^~~~
[Hydro](https://hydro.ac)提供评测服务
# 状态 耗时 内存占用
#1 Accepted 5ms 412.0 KiB
#2 Accepted 5ms 540.0 KiB
#3 Wrong Answer Read 9, expect 2090. 5ms 540.0 KiB
#4 Wrong Answer Read 4, expect 1117. 7ms 668.0 KiB
#5 Wrong Answer Read 3, expect 939. 8ms 796.0 KiB

信息

递交者
类型
递交
题目
5 城市中的最短路径
语言
C++
递交时间
2023-07-08 07:57:23
评测时间
2023-07-08 07:57:23
评测机
分数
40
总耗时
31ms
峰值内存
796.0 KiB