QOJ.ac
QOJ
ID | 题目 | 提交者 | 结果 | 用时 | 内存 | 语言 | 文件大小 | 提交时间 | 测评时间 |
---|---|---|---|---|---|---|---|---|---|
#400796 | #6749. Target | HuangHanSheng | Compile Error | / | / | C++98 | 507b | 2024-04-27 16:13:12 | 2024-04-27 16:13:13 |
Due to the privacy settings of the submitter, you are not allowed to view this code.
詳細信息
answer.code: In function ‘int main()’: answer.code:7:11: error: ‘tuple’ was not declared in this scope 7 | queue<tuple<double, std::string>> q; | ^~~~~ answer.code:7:11: note: ‘std::tuple’ is only available from C++11 onwards answer.code:7:39: error: template argument 1 is invalid 7 | queue<tuple<double, std::string>> q; | ^ answer.code:7:39: error: template argument 2 is invalid answer.code:9:5: error: ‘q’ was not declared in this scope 9 | q.push({a, ""}); | ^ answer.code:9:12: warning: extended initializer lists only available with ‘-std=c++11’ or ‘-std=gnu++11’ [-Wc++11-extensions] 9 | q.push({a, ""}); | ^ answer.code:11:14: warning: structured bindings only available with ‘-std=c++17’ or ‘-std=gnu++17’ [-Wc++17-extensions] 11 | auto [x, cnt] = q.front(); | ^ answer.code:11:14: error: ISO C++ forbids declaration of ‘structured binding’ with no type [-fpermissive] 11 | auto [x, cnt] = q.front(); | ^~~~~~~~ answer.code:11:14: error: structured binding declaration cannot be C++98 ‘auto’ answer.code:11:14: error: structured binding declaration cannot have type ‘int’ answer.code:11:14: note: type must be cv-qualified ‘auto’ or reference to cv-qualified ‘auto’ answer.code:20:16: warning: extended initializer lists only available with ‘-std=c++11’ or ‘-std=gnu++11’ [-Wc++11-extensions] 20 | q.push({x * 0.5, cnt + '1'}); | ^ answer.code:21:16: warning: extended initializer lists only available with ‘-std=c++11’ or ‘-std=gnu++11’ [-Wc++11-extensions] 21 | q.push({(x - 1) * 0.5 + 1.0, cnt + '2'}); | ^