记录详情

Compile Error

foo.cc:12:9: error: 'INT_MAX' was not declared in this scope
   12 | int num=INT_MAX,nn;
      |         ^~~~~~~
foo.cc:2:1: note: 'INT_MAX' is defined in header '<climits>'; did you forget to '#include <climits>'?
    1 | #include<iostream>
  +++ |+#include <climits>
    2 | using namespace std;
foo.cc: In function 'int f(int, int*, int*, int*, int, int&)':
foo.cc:17:25: error: 'nn' was not declared in this scope; did you mean 'n'?
   17 |                         nn+=a[i];
      |                         ^~
      |                         n
foo.cc:21:28: error: 'nn' was not declared in this scope; did you mean 'n'?
   21 |                         if(nn<num)num=nn;
      |                            ^~
      |                            n
foo.cc:26:1: warning: control reaches end of non-void function [-Wreturn-type]
   26 | }
      | ^
[Hydro](https://hydro.ac)提供评测服务

信息

递交者
类型
递交
题目
5 城市中的最短路径
比赛
2022暑期青少年社团(告别赛)
语言
C++
递交时间
2022-08-21 21:22:47
评测时间
2022-08-21 21:22:47
评测机
分数
0
总耗时
0ms
峰值内存
0 Bytes