Borderou de evaluare (job #3151177)

Utilizator victorzarzuZarzu Victor victorzarzu Data 19 septembrie 2023 23:39:59
Problema Heavy Path Decomposition Status done
Runda Arhiva educationala Compilator cpp-64 | Vezi sursa
Scor 0

Raport evaluator

Eroare de compilare: main.cpp: In function 'void dfs(int, int)': main.cpp:29:3: error: reference to 'size' is ambiguous 29 | size[node] = 1; | ^~~~ In file included from /usr/include/c++/12.2.1/string:52, from /usr/include/c++/12.2.1/bits/locale_classes.h:40, from /usr/include/c++/12.2.1/bits/ios_base.h:41, from /usr/include/c++/12.2.1/ios:42, from /usr/include/c++/12.2.1/ostream:38, from /usr/include/c++/12.2.1/iostream:39, from main.cpp:1: /usr/include/c++/12.2.1/bits/range_access.h:274:5: note: candidates are: 'template<class _Tp, long unsigned int _Nm> constexpr std::size_t std::size(const _Tp (&)[_Nm])' 274 | size(const _Tp (&)[_Nm]) noexcept | ^~~~ /usr/include/c++/12.2.1/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())) | ^~~~ main.cpp:12:106: note: 'int size [100001]' 12 | int vals[n_max], seq[n_max], level[n_max], heavy[n_max], parent[n_max], arb[4 * n_max], position[n_max], size[n_max]; | ^~~~ main.cpp:35:7: error: reference to 'size' is ambiguous 35 | size[node] += size[ngh]; | ^~~~ /usr/include/c++/12.2.1/bits/range_access.h:274:5: note: candidates are: 'template<class _Tp, long unsigned int _Nm> constexpr std::size_t std::size(const _Tp (&)[_Nm])' 274 | size(const _Tp (&)[_Nm]) noexcept | ^~~~ /usr/include/c++/12.2.1/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())) | ^~~~ main.cpp:12:106: note: 'int size [100001]' 12 | int vals[n_max], seq[n_max], level[n_max], heavy[n_max], parent[n_max], arb[4 * n_max], position[n_max], size[n_max]; | ^~~~ main.cpp:35:21: error: reference to 'size' is ambiguous 35 | size[node] += size[ngh]; | ^~~~ /usr/include/c++/12.2.1/bits/range_access.h:274:5: note: candidates are: 'template<class _Tp, long unsigned int _Nm> constexpr std::size_t std::size(const _Tp (&)[_Nm])' 274 | size(const _Tp (&)[_Nm]) noexcept | ^~~~ /usr/include/c++/12.2.1/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())) | ^~~~ main.cpp:12:106: note: 'int size [100001]' 12 | int vals[n_max], seq[n_max], level[n_max], heavy[n_max], parent[n_max], arb[4 * n_max], position[n_max], size[n_max]; | ^~~~ main.cpp:37:10: error: reference to 'size' is ambiguous 37 | if(size[ngh] > maximum) { | ^~~~ /usr/include/c++/12.2.1/bits/range_access.h:274:5: note: candidates are: 'template<class _Tp, long unsigned int _Nm> constexpr std::size_t std::size(const _Tp (&)[_Nm])' 274 | size(const _Tp (&)[_Nm]) noexcept | ^~~~ Non zero exit status: 1

Ceva nu functioneaza?