/in/foo.cc: In lambda function:
/in/foo.cc:46:25: error: use of 'auto' in lambda parameter declaration only available with -std=c++14 or -std=gnu++14
auto find = [&](auto self, int x) -> bool {
^~~~
/in/foo.cc: In lambda function:
/in/foo.cc:49:65: error: 'self' cannot be used as a function
if (p[y] == -1 || (!vis[p[y]] && self(self, p[y]))) {
^
/in/foo.cc: In lambda function:
/in/foo.cc:56:28: error: no match for call to '(solve()::<lambda(long long int)>::<lambda(int, long long int)>) (solve()::<lambda(long long int)>::<lambda(int, long long int)>&, long long int&)'
return find(find, x);
^
/in/foo.cc:46:46: note: candidate: solve()::<lambda(long long int)>::<lambda(int, long long int)>
auto find = [&](auto self, int x) -> bool {
^~~~
/in/foo.cc:46:46: note: no known conversion for argument 1 from 'solve()::<lambda(long long int)>::<lambda(int, long long int)>' to 'int'