Problem basement
User Schzeey2
Submission Time 2024-01-18 02:05:11
Score 0
Max Time N/A
Max Memory N/A

Compile Error

basement.cpp: In function ‘int main()’:
basement.cpp:21:29: error: invalid use of non-static member function ‘void std::vector<_Tp, _Alloc>::clear() [with _Tp = int; _Alloc = std::allocator<int>]’
21 | lastLoc[arr[i]].clear;
In file included from /usr/include/c++/9/vector:67,
from /usr/include/c++/9/functional:62,
from /usr/include/c++/9/pstl/glue_algorithm_defs.h:13,
from /usr/include/c++/9/algorithm:71,
from /usr/include/x86_64-linux-gnu/c++/9/bits/stdc++.h:65,
from basement.cpp:1:
/usr/include/c++/9/bits/stl_vector.h:1495:7: note: declared here
1495 | clear() _GLIBCXX_NOEXCEPT
| ^~~~~