QOJ.ac
QOJ
ID | 题目 | 提交者 | 结果 | 用时 | 内存 | 语言 | 文件大小 | 提交时间 | 测评时间 |
---|---|---|---|---|---|---|---|---|---|
#261429 | #7749. A Simple MST Problem | ucup-team2499# | Compile Error | / | / | C++20 | 3.3kb | 2023-11-22 21:30:11 | 2023-11-22 21:30:11 |
Due to the privacy settings of the submitter, you are not allowed to view this code.
详细
answer.code: In function ‘int brute_force(int, int, auto:11&)’: answer.code:14:10: error: ‘function’ is not a member of ‘std’ 14 | std::function<int(int)> getf = [&](int node) { | ^~~~~~~~ answer.code:4:1: note: ‘std::function’ is defined in header ‘<functional>’; did you forget to ‘#include <functional>’? 3 | #include <numeric> +++ |+#include <functional> 4 | answer.code:14:19: error: expected primary-expression before ‘int’ 14 | std::function<int(int)> getf = [&](int node) { | ^~~ answer.code: In lambda function: answer.code:18:13: error: there are no arguments to ‘getf’ that depend on a template parameter, so a declaration of ‘getf’ must be available [-fpermissive] 18 | x = getf(x), y = getf(y); | ^~~~ answer.code:18:13: note: (if you use ‘-fpermissive’, G++ will accept your code, but allowing the use of an undeclared name is deprecated) answer.code:18:26: error: there are no arguments to ‘getf’ that depend on a template parameter, so a declaration of ‘getf’ must be available [-fpermissive] 18 | x = getf(x), y = getf(y); | ^~~~ answer.code: In instantiation of ‘int brute_force(int, int, auto:11&) [with auto:11 = std::vector<int>]’: answer.code:130:26: required from here answer.code:18:17: error: ‘getf’ was not declared in this scope; did you mean ‘getw’? 18 | x = getf(x), y = getf(y); | ~~~~^~~ | getw answer.code:18:30: error: ‘getf’ was not declared in this scope, and no declarations were found by argument-dependent lookup at the point of instantiation 18 | x = getf(x), y = getf(y); | ~~~~^~~ answer.code:35:17: error: ‘getf’ was not declared in this scope; did you mean ‘getw’? 35 | if (getf(p.first) == getf(p.second)) { | ~~~~^~~~~~~~~ | getw answer.code:35:34: error: ‘getf’ was not declared in this scope, and no declarations were found by argument-dependent lookup at the point of instantiation [-fpermissive] 35 | if (getf(p.first) == getf(p.second)) { | ~~~~^~~~~~~~~~