QOJ.ac

QOJ

ID题目提交者结果用时内存语言文件大小提交时间测评时间
#540712#8937. Stage: Agausscrabucup-team4851#Compile Error//C++141.4kb2024-08-31 17:44:052024-08-31 17:44:06

詳細信息

answer.code: In function ‘int main()’:
answer.code:43:5: error: ‘sort’ was not declared in this scope; did you mean ‘short’?
   43 |     sort(e+1,e+n+1);
      |     ^~~~
      |     short
answer.code:49:15: error: ‘strlen’ was not declared in this scope
   49 |         int m=strlen(e[i].s);
      |               ^~~~~~
answer.code:6:1: note: ‘strlen’ is defined in header ‘<cstring>’; did you forget to ‘#include <cstring>’?
    5 | #include<map>
  +++ |+#include <cstring>
    6 | using namespace std;
answer.code:54:15: error: ‘strlen’ was not declared in this scope
   54 |         int m=strlen(e[i].s);
      |               ^~~~~~
answer.code:54:15: note: ‘strlen’ is defined in header ‘<cstring>’; did you forget to ‘#include <cstring>’?
answer.code:18:21: warning: ignoring return value of ‘int scanf(const char*, ...)’ declared with attribute ‘warn_unused_result’ [-Wunused-result]
   18 | #define sci(a) scanf("%d",&(a))
      |                ~~~~~^~~~~~~~~~~
answer.code:38:5: note: in expansion of macro ‘sci’
   38 |     sci(n);
      |     ^~~
answer.code:40:14: warning: ignoring return value of ‘int scanf(const char*, ...)’ declared with attribute ‘warn_unused_result’ [-Wunused-result]
   40 |         scanf("%s%d",e[i].s,&e[i].v);
      |         ~~~~~^~~~~~~~~~~~~~~~~~~~~~~