/ Vijos /

记录详情

Compile Error

foo.cc: In function 'int main()':
foo.cc:24:9: error: 'sort' was not declared in this scope; did you mean 'qsort'?
   24 |         sort(number, number + n); // 从小到大排序
      |         ^~~~
      |         qsort
foo.cc: At global scope:
foo.cc:91:5: error: redefinition of 'int t'
   91 | int t, n;
      |     ^
foo.cc:9:5: note: 'int t' previously declared here
    9 | int t, n;
      |     ^
foo.cc:91:8: error: redefinition of 'int n'
   91 | int t, n;
      |        ^
foo.cc:9:8: note: 'int n' previously declared here
    9 | int t, n;
      |        ^
foo.cc:92:5: error: redefinition of 'int number [16]'
   92 | int number[max_value];
      |     ^~~~~~
foo.cc:10:5: note: 'int number [16]' previously declared here
   10 | int number[max_value];
      |     ^~~~~~
foo.cc:93:5: error: redefinition of 'int answer'
   93 | int answer;
      |     ^~~~~~
foo.cc:11:5: note: 'int answer' previously declared here
   11 | int answer;
      |     ^~~~~~
foo.cc:95:5: error: redefinition of 'int main()'
   95 | int main() {
      |     ^~~~
foo.cc:13:5: note: 'int main()' previously defined here
   13 | int main() {
      |     ^~~~
foo.cc: In function 'int main()':
foo.cc:106:9: error: 'sort' was not declared in this scope; did you mean 'qsort'?
  106 |         sort(number, number + n); // 从小到大排序
      |         ^~~~
      |         qsort
[Hydro](https://hydro.ac)提供评测服务

信息

递交者
类型
递交
题目
P1039 最小差距
语言
C++
递交时间
2021-12-12 17:33:49
评测时间
2021-12-12 17:33:49
评测机
分数
0
总耗时
0ms
峰值内存
0 Bytes