/in/foo.cc: In function 'int calcp(int, int)':
/in/foo.cc:54:21: error: reference to 'end' is ambiguous
int l=start[p]-1,r=end[p];
^~~
/in/foo.cc:7:90: note: candidates are: int end [100010]
int n,m,en,z[maxn*3],f[maxn][20],q[maxn],depth[maxn],sum[maxn*3][2],fd[maxn],start[maxn],end[maxn],value[maxn];
^~~
In file included from /usr/include/c++/7/utility:76:0,
from /usr/include/c++/7/algorithm:60,
from /in/foo.cc:4:
/usr/include/c++/7/initializer_list:99:5: note: template<class _Tp> constexpr const _Tp* std::end(std::initializer_list<_Tp>)
end(initializer_list<_Tp> __ils) noexcept
^~~
/in/foo.cc: In function 'int main()':
/in/foo.cc:109:3: error: reference to 'end' is ambiguous
end[now]=cnt;
^~~
/in/foo.cc:7:90: note: candidates are: int end [100010]
int n,m,en,z[maxn*3],f[maxn][20],q[maxn],depth[maxn],sum[maxn*3][2],fd[maxn],start[maxn],end[maxn],value[maxn];
^~~
In file included from /usr/include/c++/7/utility:76:0,
from /usr/include/c++/7/algorithm:60,
from /in/foo.cc:4:
/usr/include/c++/7/initializer_list:99:5: note: template<class _Tp> constexpr const _Tp* std::end(std::initializer_list<_Tp>)
end(initializer_list<_Tp> __ils) noexcept
^~~
/in/foo.cc:110:23: error: reference to 'end' is ambiguous
sort(z+start[now],z+end[now]+1);
^~~
/in/foo.cc:7:90: note: candidates are: int end [100010]
int n,m,en,z[maxn*3],f[maxn][20],q[maxn],depth[maxn],sum[maxn*3][2],fd[maxn],start[maxn],end[maxn],value[maxn];
^~~
In file included from /usr/include/c++/7/utility:76:0,
from /usr/include/c++/7/algorithm:60,
from /in/foo.cc:4:
/usr/include/c++/7/initializer_list:99:5: note: template<class _Tp> constexpr const _Tp* std::end(std::initializer_list<_Tp>)
end(initializer_list<_Tp> __ils) noexcept
^~~
/in/foo.cc:111:7: error: reference to 'end' is ambiguous
sum[end[now]][0]=z[end[now]];
^~~
/in/foo.cc:7:90: note: candidates are: int end [100010]
int n,m,en,z[maxn*3],f[maxn][20],q[maxn],depth[maxn],sum[maxn*3][2],fd[maxn],start[maxn],end[maxn],value[maxn];
^~~
In file included from /usr/include/c++/7/utility:76:0,
from /usr/include/c++/7/algorithm:60,
from /in/foo.cc:4:
/usr/include/c++/7/initializer_list:99:5: note: template<class _Tp> constexpr const _Tp* std::end(std::initializer_list<_Tp>)
end(initializer_list<_Tp> __ils) noexcept
^~~
/in/foo.cc:111:22: error: reference to 'end' is ambiguous
sum[end[now]][0]=z[end[now]];
^~~
/in/foo.cc:7:90: note: candidates are: int end [100010]
int n,m,en,z[maxn*3],f[maxn][20],q[maxn],depth[maxn],sum[maxn*3][2],fd[maxn],start[maxn],end[maxn],value[maxn];
^~~
In file included from /usr/include/c++/7/utility:76:0,
from /usr/include/c++/7/algorithm:60,
from /in/foo.cc:4:
/usr/include/c++/7/initializer_list:99:5: note: template<class _Tp> constexpr const _Tp* std::end(std::initializer_list<_Tp>)
end(initializer_list<_Tp> __ils) noexcept
^~~
/in/foo.cc:112:7: error: reference to 'end' is ambiguous
sum[end[now]][1]=0;
^~~
/in/foo.cc:7:90: note: candidates are: int end [100010]
int n,m,en,z[maxn*3],f[maxn][20],q[maxn],depth[maxn],sum[maxn*3][2],fd[maxn],start[maxn],end[maxn],value[maxn];
^~~
In file included from /usr/include/c++/7/utility:76:0,
from /usr/include/c++/7/algorithm:60,
from /in/foo.cc:4:
/usr/include/c++/7/initializer_list:99:5: note: template<class _Tp> constexpr const _Tp* std::end(std::initializer_list<_Tp>)
end(initializer_list<_Tp> __ils) noexcept
^~~
/in/foo.cc:113:14: error: reference to 'end' is ambiguous
for (int a=end[now]-1;a>=start[now];a--)
^~~
/in/foo.cc:7:90: note: candidates are: int end [100010]
int n,m,en,z[maxn*3],f[maxn][20],q[maxn],depth[maxn],sum[maxn*3][2],fd[maxn],start[maxn],end[maxn],value[maxn];
^~~
In file included from /usr/include/c++/7/utility:76:0,
from /usr/include/c++/7/algorithm:60,
from /in/foo.cc:4:
/usr/include/c++/7/initializer_list:99:5: note: template<class _Tp> constexpr const _Tp* std::end(std::initializer_list<_Tp>)
end(initializer_list<_Tp> __ils) noexcept
^~~
/in/foo.cc:117:16: error: reference to 'end' is ambiguous
if ((a&1)==(end[now]&1)) sum[a][0]+=z[a];
^~~
/in/foo.cc:7:90: note: candidates are: int end [100010]
int n,m,en,z[maxn*3],f[maxn][20],q[maxn],depth[maxn],sum[maxn*3][2],fd[maxn],start[maxn],end[maxn],value[maxn];
^~~
In file included from /usr/include/c++/7/utility:76:0,
from /usr/include/c++/7/algorithm:60,
from /in/foo.cc:4:
/usr/include/c++/7/initializer_list:99:5: note: template<class _Tp> constexpr const _Tp* std::end(std::initializer_list<_Tp>)
end(initializer_list<_Tp> __ils) noexcept
^~~