QOJ.ac

QOJ

ID题目提交者结果用时内存语言文件大小提交时间测评时间
#515571#6798. String Theoryucup-team1005Compile Error//C++143.0kb2024-08-11 18:49:122024-08-11 18:49:12

详细

answer.code:22:2: error: call to non-‘constexpr’ function ‘<lambda()>’
   18 | static constexpr UIT inv = []() {
      |                            ~~~~~~
   19 |     UIT ret = mod;
      |     ~~~~~~~~~~~~~~
   20 |     for(int i = 0; i < 6; i++) ret *= 2 - ret * mod;
      |     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   21 |     return ret;
      |     ~~~~~~~~~~~
   22 | }();
      | ~^~
answer.code:18:28: note: ‘<lambda()>’ is not usable as a ‘constexpr’ function because:
   18 | static constexpr UIT inv = []() {
      |                            ^
answer.code:18:28: note: lambdas are implicitly ‘constexpr’ only in C++17 and later
answer.code: In function ‘int main()’:
answer.code:107:26: warning: structured bindings only available with ‘-std=c++17’ or ‘-std=gnu++17’ [-Wc++17-extensions]
  107 |                 for(auto [l, r, p] : run){
      |                          ^