0_0_39539259_13855.cpp: In function 'void dfs_1(long long int)':
0_0_39539259_13855.cpp:83:30: error: reference to 'size' is ambiguous
83 | dep[u]=dep[fa[u]]+1; size[u]=1; son[u]=0;
| ^~~~
In file included from gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/map:65,
from 0_0_39539259_13855.cpp:1:
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/bits/range_access.h:274:5: note: candidates are: 'template<class _Tp, long long unsigned int _Nm> constexpr std::size_t std::size(const _Tp (&)[_Nm])'
274 | size(const _Tp (&)[_Nm]) noexcept
| ^~~~
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/bits/range_access.h:264:5: note: 'template<class _Container> constexpr decltype (__cont.size()) std::size(const _Container&)'
264 | size(const _Container& __cont) noexcept(noexcept(__cont.size()))
| ^~~~
0_0_39539259_13855.cpp:33:5: note: 'long long int size [100008]'
33 | int size[V],fa[V],w[V],top[V],rk[V],dep[V],son[V];
| ^~~~
0_0_39539259_13855.cpp:89:21: error: reference to 'size' is ambiguous
89 | if (size[v]>size[son[u]]) son[u]=v;
| ^~~~
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/bits/range_access.h:274:5: note: candidates are: 'template<class _Tp, long long unsigned int _Nm> constexpr std::size_t std::size(const _Tp (&)[_Nm])'
274 | size(const _Tp (&)[_Nm]) noexcept
| ^~~~
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/bits/range_access.h:264:5: note: 'template<class _Container> constexpr decltype (__cont.size()) std::size(const _Container&)'
264 | size(const _Container& __cont) noexcept(noexcept(__cont.size()))
| ^~~~
0_0_39539259_13855.cpp:33:5: note: 'long long int size [100008]'
33 | int size[V],fa[V],w[V],top[V],rk[V],dep[V],son[V];
| ^~~~
0_0_39539259_13855.cpp:89:29: error: reference to 'size' is ambiguous
89 | if (size[v]>size[son[u]]) son[u]=v;
| ^~~~
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/bits/range_access.h:274:5: note: candidates are: 'template<class _Tp, long long unsigned int _Nm> constexpr std::size_t std::size(const _Tp (&)[_Nm])'
274 | size(const _Tp (&)[_Nm]) noexcept
| ^~~~
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/bits/range_access.h:264:5: note: 'template<class _Container> constexpr decltype (__cont.size()) std::size(const _Container&)'
264 | size(const _Container& __cont) noexcept(noexcept(__cont.size()))
| ^~~~
0_0_39539259_13855.cpp:33:5: note: 'long long int size [100008]'
33 | int size[V],fa[V],w[V],top[V],rk[V],dep[V],son[V];
| ^~~~
0_0_39539259_13855.cpp:90:17: error: reference to 'size' is ambiguous
90 | size[u]+=size[v];
| ^~~~
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/bits/range_access.h:274:5: note: candidates are: 'template<class _Tp, long long unsigned int _Nm> constexpr std::size_t std::size(const _Tp (&)[_Nm])'
274 | size(const _Tp (&)[_Nm]) noexcept
| ^~~~
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/bits/range_access.h:264:5: note: 'template<class _Container> constexpr decltype (__cont.size()) std::size(const _Container&)'
264 | size(const _Container& __cont) noexcept(noexcept(__cont.size()))
| ^~~~
0_0_39539259_13855.cpp:33:5: note: 'long long int size [100008]'
33 | int size[V],fa[V],w[V],top[V],rk[V],dep[V],son[V];
| ^~~~
0_0_39539259_13855.cpp:90:26: error: reference to 'size' is ambiguous
90 | size[u]+=size[v];
| ^~~~
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/bits/range_access.h:274:5: note: candidates are: 'template<class _Tp, long long unsigned int _Nm> constexpr std::size_t std::size(const _Tp (&)[_Nm])'
274 | size(const _Tp (&)[_Nm]) noexcept
| ^~~~
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/bits/range_access.h:264:5: note: 'template<class _Container> constexpr decltype (__cont.size()) std::size(const _Container&)'
264 | size(const _Container& __cont) noexcept(noexcept(__cont.size()))
| ^~~~
0_0_39539259_13855.cpp:33:5: note: 'long long int size [100008]'
33 | int size[V],fa[V],w[V],top[V],rk[V],dep[V],son[V];
| ^~~~
0_0_39539259_13855.cpp: In function 'void update(long long int, long long int)':
0_0_39539259_13855.cpp:106:23: error: expected ';' before 'while'
106 | int u=top[x];w
| ^
| ;
107 | while (fa[u]){
| ~~~~~
0_0_39539259_13855.cpp: In function 'long long int query(long long int, long long int)':
0_0_39539259_13855.cpp:123:61: error: reference to 'size' is ambiguous
123 | LL sum=Ts.query(w[son[x]],w[son[x]]+size[son[x]]-1,1,n,1);
| ^~~~
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/bits/range_access.h:274:5: note: candidates are: 'template<class _Tp, long long unsigned int _Nm> constexpr std::size_t std::size(const _Tp (&)[_Nm])'
274 | size(const _Tp (&)[_Nm]) noexcept
| ^~~~
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/bits/range_access.h:264:5: note: 'template<class _Container> constexpr decltype (__cont.size()) std::size(const _Container&)'
264 | size(const _Container& __cont) noexcept(noexcept(__cont.size()))
| ^~~~
0_0_39539259_13855.cpp:33:5: note: 'long long int size [100008]'
33 | int size[V],fa[V],w[V],top[V],rk[V],dep[V],son[V];
| ^~~~
0_0_39539259_13855.cpp:127:53: error: reference to 'size' is ambiguous
127 | LL sum=Ts.query(w[top[x]],w[top[x]]+size[top[x]]-1,1,n,1);
| ^~~~
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/bits/range_access.h:274:5: note: candidates are: 'template<class _Tp, long long unsigned int _Nm> constexpr std::size_t std::size(const _Tp (&)[_Nm])'
274 | size(const _Tp (&)[_Nm]) noexcept
| ^~~~
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/bits/range_access.h:264:5: note: 'template<class _Container> constexpr decltype (__cont.size()) std::size(const _Container&)'
264 | size(const _Container& __cont) noexcept(noexcept(__cont.size()))
| ^~~~
0_0_39539259_13855.cpp:33:5: note: 'long long int size [100008]'
33 | int size[V],fa[V],w[V],top[V],rk[V],dep[V],son[V];
| ^~~~
0_0_39539259_13855.cpp:138:53: error: reference to 'size' is ambiguous
138 | LL sum=Ts.query(w[son[y]],w[son[y]]+size[son[y]]-1,1,n,1);
| ^~~~
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/bits/range_access.h:274:5: note: candidates are: 'template<class _Tp, long long unsigned int _Nm> constexpr std::size_t std::size(const _Tp (&)[_Nm])'
274 | size(const _Tp (&)[_Nm]) noexcept
| ^~~~
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/bits/range_access.h:264:5: note: 'template<class _Container> constexpr decltype (__cont.size()) std::size(const _Container&)'
264 | size(const _Container& __cont) noexcept(noexcept(__cont.size()))
| ^~~~
0_0_39539259_13855.cpp:33:5: note: 'long long int size [100008]'
33 | int size[V],fa[V],w[V],top[V],rk[V],dep[V],son[V];
| ^~~~
0_0_39539259_13855.cpp:143:63: error: reference to 'size' is ambiguous
143 | LL sum=Ts.query(1,n,1,n,1)-Ts.query(w[x],w[x]+size[x]-1,1,n,1);
| ^~~~
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/bits/range_access.h:274:5: note: candidates are: 'template<class _Tp, long long unsigned int _Nm> constexpr std::size_t std::size(const _Tp (&)[_Nm])'
274 | size(const _Tp (&)[_Nm]) noexcept
| ^~~~
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/bits/range_access.h:264:5: note: 'template<class _Container> constexpr decltype (__cont.size()) std::size(const _Container&)'
264 | size(const _Container& __cont) noexcept(noexcept(__cont.size()))
| ^~~~
0_0_39539259_13855.cpp:33:5: note: 'long long int size [100008]'
33 | int size[V],fa[V],w[V],top[V],rk[V],dep[V],son[V];
| ^~~~
At global scope:
cc1plus.exe: error: '::main' must return 'int'
0_0_39539259_13855.cpp: In function 'int main()':
0_0_39539259_13855.cpp:171:59: error: reference to 'size' is ambiguous
171 | LL sum=Ts.query(w[1],w[1]+size[1]-1,1,n,1);
| ^~~~
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/bits/range_access.h:274:5: note: candidates are: 'template<class _Tp, long long unsigned int _Nm> constexpr std::size_t std::size(const _Tp (&)[_Nm])'
274 | size(const _Tp (&)[_Nm]) noexcept
| ^~~~
gcc-13.1.0/lib/gcc/x86_64-w64-mingw32/13.1.0/include/c++/bits/range_access.h:264:5: note: 'template<class _Container> constexpr decltype (__cont.size()) std::size(const _Container&)'
264 | size(const _Container& __cont) noexcept(noexcept(__cont.size()))
|
|