Problem swap
User PlayVoltz
Submission Time 2024-03-06 13:16:38
Score 0
Max Time N/A
Max Memory N/A

Compile Error

swap.cpp: In function ‘void merge(int, int, int)’:
swap.cpp:42:62: error: reference to ‘end’ is ambiguous
42 | else if (start[t][a]==start[t][b])line[t][a]=0, start[t][a]=end[t][b];
| ^~~
In file included from /usr/include/c++/9/vector:69,
from swap.h:1,
from swap.cpp:1:
/usr/include/c++/9/bits/range_access.h:107:37: note: candidates are: ‘template<class _Tp> const _Tp* std::end(const std::valarray<_Tp>&)’
107 | template<typename _Tp> const _Tp* end(const valarray<_Tp>&);
| ^~~
/usr/include/c++/9/bits/range_access.h:106:31: note: ‘template<class _Tp> _Tp* std::end(std::valarray<_Tp>&)’
106 | template<typename _Tp> _Tp* end(valarray<_Tp>&);
| ^~~
/usr/include/c++/9/bits/range_access.h:97:5: note: