/ Vijos /

记录详情

Compile Error

/in/foo.cc: In function 'int main()':
/in/foo.cc:22:34: error: use of 'auto' in lambda parameter declaration only available with -std=c++14 or -std=gnu++14
     auto dfs = [&](int x, int y, auto self) -> int {
                                  ^~~~
/in/foo.cc: In lambda function:
/in/foo.cc:35:67: error: 'self' cannot be used as a function
                     dp[x][y] = max(dp[x][y], 1 + self(tx, ty, self));
                                                                   ^
/in/foo.cc: In function 'int main()':
/in/foo.cc:46:41: error: no match for call to '(main()::<lambda(int, int, int)>) (int&, int&, main()::<lambda(int, int, int)>&)'
             ans = max(ans, dfs(i, j, dfs));
                                         ^
/in/foo.cc:22:48: note: candidate: main()::<lambda(int, int, int)>
     auto dfs = [&](int x, int y, auto self) -> int {
                                                ^~~
/in/foo.cc:22:48: note:   no known conversion for argument 3 from 'main()::<lambda(int, int, int)>' to 'int'

信息

递交者
类型
递交
题目
P1011 清帝之惑之顺治
语言
C++
递交时间
2024-10-16 17:42:20
评测时间
2024-10-16 17:42:20
评测机
分数
0
总耗时
0ms
峰值内存
0 Bytes