QOJ.ac

QOJ

ID题目提交者结果用时内存语言文件大小提交时间测评时间
#402854#8320. 种树jxy2012Compile Error//C++231.9kb2024-05-01 16:42:382024-05-01 16:42:40

详细

answer.code: In function ‘void init(int)’:
answer.code:8:22: error: ‘min’ was not declared in this scope
    8 |         for (int i = min(s, n); i >= 0 && i >= s - i; i--) {
      |                      ^~~
answer.code:8:22: note: suggested alternatives:
In file included from /usr/include/c++/13/algorithm:61,
                 from /usr/include/x86_64-linux-gnu/c++/13/bits/stdc++.h:51,
                 from answer.code:1:
/usr/include/c++/13/bits/stl_algo.h:5785:5: note:   ‘std::min’
 5785 |     min(initializer_list<_Tp> __l, _Compare __comp)
      |     ^~~
In file included from /usr/include/c++/13/bits/ranges_algo.h:39,
                 from /usr/include/c++/13/algorithm:63:
/usr/include/c++/13/bits/ranges_util.h:733:29: note:   ‘std::ranges::min’
  733 |   inline constexpr __min_fn min{};
      |                             ^~~
answer.code: At global scope:
answer.code:20:1: error: ‘vector’ does not name a type
   20 | vector<int> G[75];
      | ^~~~~~
answer.code: In function ‘void dfs(int, int)’:
answer.code:23:19: error: ‘G’ was not declared in this scope
   23 |     for (auto v : G[u]) {
      |                   ^
answer.code: In function ‘__int128 unsigned encode(int, const int*)’:
answer.code:38:9: error: ‘G’ was not declared in this scope
   38 |         G[i].clear();
      |         ^
answer.code:41:9: error: ‘G’ was not declared in this scope
   41 |         G[p[i]].push_back(i);
      |         ^
grader_encoder.cpp: In function ‘__int128 unsigned {anonymous}::read()’:
grader_encoder.cpp:7:45: warning: ignoring return value of ‘size_t fread(void*, size_t, size_t, FILE*)’ declared with attribute ‘warn_unused_result’ [-Wunused-result]
    7 | #define gc() ((buff == buf + 100000 ? (fread(buf,1,100000,stdin),buff = buf) : 0),*(buff++))
      |                                        ~~~~~^~~~~~~~~~~~~~~~~~~~
grader_encoder.cpp:12:17: note: in expansion of macro ‘gc’
   12 |         int c = gc();
      |                 ^~
grader_encoder.cpp:7:45: warning: ignoring return value of ‘size_t fread(void*, size_t, size_t, FILE*)’ declared with attribute ‘warn_unused_result’ [-Wunused-result]
    7 | #define gc() ((buff == buf + 100000 ? (fread(buf,1,100000,stdin),buff = buf) : 0),*(buff++))
      |                                        ~~~~~^~~~~~~~~~~~~~~~~~~~
grader_encoder.cpp:13:39: note: in expansion of macro ‘gc’
   13 |         while(c < '0' || c > '9') c = gc();
      |                                       ^~
grader_encoder.cpp:7:45: warning: ignoring return value of ‘size_t fread(void*, size_t, size_t, FILE*)’ declared with attribute ‘warn_unused_result’ [-Wunused-result]
    7 | #define gc() ((buff == buf + 100000 ? (fread(buf,1,100000,stdin),buff = buf) : 0),*(buff++))
      |                                        ~~~~~^~~~~~~~~~~~~~~~~~~~
grader_encoder.cpp:14:62: note: in expansion of macro ‘gc’
   14 |         while(c >= '0' && c <= '9') x = x * 10 + c - '0',c = gc();
      |                                                              ^~