Anthony.cpp: In function 'std::vector<int> Mark(int, int, int, int, std::vector<int>, std::vector<int>)':
Anthony.cpp:22:3: error: reference to 'index' is ambiguous
22 | index[0] = 1;
| ^~~~~
Anthony.cpp:12:5: note: candidates are: 'int {anonymous}::index [20001]'
12 | int index[20001] = {};
| ^~~~~
In file included from /usr/include/string.h:432,
from /usr/include/c++/10/cstring:42,
from /usr/include/x86_64-linux-gnu/c++/10/bits/stdc++.h:48,
from Anthony.cpp:3:
/usr/include/strings.h:61:1: note: 'const char* index(const char*, int)'
61 | index (const char *__s, int __c) __THROW
| ^~~~~
/usr/include/strings.h:55:1: note: 'char* index(char*, int)'
55 | index (char *__s, int __c) __THROW
| ^~~~~
Anthony.cpp:31:12: error: reference to 'index' is ambiguous
31 | if(index[child]==0){
| ^~~~~
Anthony.cpp:12:5: note: candidates are: 'int {anonymous}::index [20001]'
12 | int index[20001] = {};
| ^~~~~
In file included from /usr/include/string.h:432,
from /usr/include/c++/10/cstring:42,
from /usr/include/x86_64-linux-gnu/c++/10/bits/stdc++.h:48,
from Anthony.cpp:3:
/usr/include/strings.h:61:1: note: 'const char* index(const char*, int)'
61 | index (const char *__s, int __c) __THROW
| ^~~~~
/usr/include/strings.h:55:1: note: 'char* index(char*, int)'
55 | index (char *__s, int __c) __THROW
| ^~~~~
Anthony.cpp:32:13: error: reference to 'index' is ambiguous
32 | index[child] = index[node] + 1;
| ^~~~~
Anthony.cpp:12:5: note: candidates are: 'int {anonymous}::index [20001]'
12 | int index[20001] = {};
| ^~~~~
In file included from /usr/include/string.h:432,
from /usr/include/c++/10/cstring:42,
from /usr/include/x86_64-linux-gnu/c++/10/bits/stdc++.h:48,
from Anthony.cpp:3:
/usr/include/strings.h:61:1: note: 'const char* index(const char*, int)'
61 | index (const char *__s, int __c) __THROW
| ^~~~~
/usr/include/strings.h:55:1: note: 'char* index(char*, int)'
55 | index (char *__s, int __c) __THROW
| ^~~~~
Anthony.cpp:32:28: error: reference to 'index' is ambiguous
32 | index[child] = index[node] + 1;
| ^~~~~
Anthony.cpp:12:5: note: candidates are: 'int {anonymous}::index [20001]'
12 | int index[20001] = {};
| ^~~~~
In file included from /usr/include/string.h:432,
from /usr/include/c++/10/cstring:42,
from /usr/include/x86_64-linux-gnu/c++/10/bits/stdc++.h:48,
from Anthony.cpp:3:
/usr/include/strings.h:61:1: note: 'const char* index(const char*, int)'
61 | index (const char *__s, int __c) __THROW
| ^~~~~
/usr/include/strings.h:55:1: note: 'char* index(char*, int)'
55 | index (char *__s, int __c) __THROW
| ^~~~~
Anthony.cpp:33:16: error: reference to 'index' is ambiguous
33 | if(index[child]==4) index[child] = 1;
| ^~~~~
Anthony.cpp:12:5: note: candidates are: 'int {anonymous}::index [20001]'
12 | int index[20001] = {};
| ^~~~~
In file included from /usr/include/string.h:432,
from /usr/include/c++/10/cstring:42,
from /usr/include/x86_64-linux-gnu/c++/10/bits/stdc++.h:48,
from Anthony.cpp:3:
/usr/include/strings.h:61:1: note: 'const char* index(const char*, int)'
61 | index (const char *__s, int __c) __THROW
| ^~~~~
/usr/include/strings.h:55:1: note: 'char* index(char*, int)'
55 | index (char *__s, int __c) __THROW
| ^~~~~
Anthony.cpp:33:33: error: reference to 'index' is ambiguous
33 | if(index[child]==4) index[child] = 1;
| ^~~~~
Anthony.cpp:12:5: note: candidates are: 'int {anonymous}::index [20001]'
12 | int index[20001] = {};
| ^~~~~
In file included from /usr/include/string.h:432,
from /usr/include/c++/10/cstring:42,
from /usr/include/x86_64-linux-gnu/c++/10/bits/stdc++.h:48,
from Anthony.cpp:3:
/usr/include/strings.h:61:1: note: 'const char* index(const char*, int)'
61 | index (const char *__s, int __c) __THROW
| ^~~~~
/usr/include/strings.h:55:1: note: 'char* index(char*, int)'
55 | index (char *__s, int __c) __THROW
| ^~~~~
Anthony.cpp:39:17: error: reference to 'index' is ambiguous
39 | int nodeA = index[U[i]];
| ^~~~~
Anthony.cpp:12:5: note: candidates are: 'int {anonymous}::index [20001]'
12 | int index[20001] = {};
| ^~~~~
In file included from /usr/include/string.h:432,
from /usr/include/c++/10/cstring:42,
from /usr/include/x86_64-linux-gnu/c++/10/bits/stdc++.h:48,
from Anthony.cpp:3:
/usr/include/strings.h:61:1: note: 'const char* index(const char*, int)'
61 | index (const char *__s, int __c) __THROW
| ^~~~~
/usr/include/strings.h:55:1: note: 'char* index(char*, int)'
55 | index (char *__s, int __c) __THROW
| ^~~~~
Anthony.cpp:40:17: error: reference to 'index' is ambiguous
40 | int nodeB = index[V[i]];
| ^~~~~
Anthony.cpp:12:5: note: candidates are: 'int {anonymous}::index [20001]'
12 | int index[20001] = {};
| ^~~~~
In file included from /usr/include/string.h:432,
from /usr/include/c++/10/cstring:42,
from /usr/include/x86_64-linux-gnu/c++/10/bits/stdc++.h:48,
from Anthony.cpp:3:
/usr/include/strings.h:61:1: note: 'const char* index(const char*, int)'
61 | index (const char *__s, int __c) __THROW
| ^~~~~
/usr/include/strings.h:55:1: note: 'char* index(char*, int)'
55 | index (char *__s, int __c) __THROW
| ^~~~~
Anthony.cpp:41:23: error: 'swap' was not declared in this scope
41 | if(nodeA > nodeB) swap(nodeA,nodeB);
| ^~~~
Anthony.cpp:41:23: note: suggested alternatives:
In file included from /usr/include/c++/10/regex:62,
from /usr/include/x86_64-linux-gnu/c++/10/bits/stdc++.h:110,
from Anthony.cpp:3:
/usr/include/c++/10/bits/regex.h:2141:5: note: 'std::__cxx11::swap'
2141 | swap(match_results<_Bi_iter, _Alloc>& __lhs,
| ^~~~
In file included from /usr/include/c++/10/bits/stl_pair.h:59,
from /usr/include/c++/10/bits/stl_algobase.h:64,
from /usr/include/c++/10/vector:60,
from Anthony.h:5,
from Anthony.cpp:1:
/usr/include/c++/10/bits/move.h:189:5: note: 'std::swap'
189 | swap(_Tp& __a, _Tp& __b)
| ^~~~
In file included from /usr/include/c++/10/exception:147,
from /usr/include/c++/10/new:41,
from /usr/include/c++/10/ext/new_allocator.h:33,
from /usr/include/x86_64-linux-gnu/c++/10/bits/c++allocator.h:33,
from /usr/include/c++/10/bits/allocator.h:46,
from /usr/include/c++/10/vector:64,
from Anthony.h:5,
from Anthony.cpp:1:
/usr/include/c++/10/bits/exception_ptr.h:169:5: note: 'std::__exception_ptr::swap'
169 | swap(exception_ptr& __lhs, exception_ptr& __rhs)
| ^~~~
Anthony.cpp: At global scope:
Anthony.cpp:12:5: warning: '{anonymous}::index' defined but not used [-Wunused-variable]
12 | int index[20001] = {};
| ^~~~~
Anthony.cpp:7:5: warning: 'int {anonymous}::FunctionExample(int, int)' defined but not used [-Wunused-function]
7 | int FunctionExample(int i, int A) {
| ^~~~~~~~~~~~~~~