Problem supertrees
User Craftless
Submission Time 2023-02-15 22:36:19
Score 0
Max Time N/A
Max Memory N/A

Compile Error

supertrees.cpp:8:1: error: ‘unordered_map’ does not name a type
8 | unordered_map<int, vector<int>> grps;
| ^~~~~~~~~~~~~
supertrees.cpp: In function ‘int construct(std::vector<std::vector<int> >)’:
supertrees.cpp:36:10: error: ‘pArr’ was not declared in this scope
36 | int N = pArr.size();
| ^~~~
supertrees.cpp:46:10: error: no match for ‘operator=’ (operand types are ‘__gnu_cxx::__alloc_traits<std::allocator<std::vector<int> >, std::vector<int> >::value_type’ {aka ‘std::vector<int>’} and ‘int’)
46 | p[i] = i;
| ^
In file included from /usr/include/c++/9/vector:72,
from supertrees.h:1,
from supertrees.cpp:1:
/usr/include/c++/9/bits/vector.tcc:198:5: note: candidate: ‘std::vector<_Tp, _Alloc>& std::vector<_Tp, _Alloc>::operator=(const std::vector<_Tp, _Alloc>&) [with _Tp = int; _Alloc = std::all