Main.cpp: In constructor 'SEGT::SEGT(int)':
Main.cpp:9:21: error: no matching function for call to 'std::vector<int>::assign(int)'
9 | tree.assign(4 * sz);
| ^
In file included from /usr/include/c++/10/vector:67,
from /usr/include/c++/10/functional:62,
from /usr/include/c++/10/pstl/glue_algorithm_defs.h:13,
from /usr/include/c++/10/algorithm:74,
from /usr/include/x86_64-linux-gnu/c++/10/bits/stdc++.h:65,
from Main.cpp:1:
/usr/include/c++/10/bits/stl_vector.h:749:7: note: candidate: 'void std::vector<_Tp, _Alloc>::assign(std::vector<_Tp, _Alloc>::size_type, const value_type&) [with _Tp = int; _Alloc = std::allocator<int>; std::vector<_Tp, _Alloc>::size_type = long unsigned int; std::vector<_Tp, _Alloc>::value_type = int]'
749 | assign(size_type __n, const value_type& __val)
| ^~~~~~
/usr/include/c++/10/bits/stl_vector.h:749:7: note: candidate expects 2 arguments, 1 provided
/usr/include/c++/10/bits/stl_vector.h:768:2: note: candidate: 'template<class _InputIterator, class> void std::vector<_Tp, _Alloc>::assign(_InputIterator, _InputIterator) [with _InputIterator = _InputIterator; <template-parameter-2-2> = <template-parameter-1-2>; _Tp = int; _Alloc = std::allocator<int>]'
768 | assign(_InputIterator __first, _InputIterator __last)
| ^~~~~~
/usr/include/c++/10/bits/stl_vector.h:768:2: note: template argument deduction/substitution failed:
Main.cpp:9:21: note: candidate expects 2 arguments, 1 provided
9 | tree.assign(4 * sz);
| ^
In file included from /usr/include/c++/10/vector:67,
from /usr/include/c++/10/functional:62,
from /usr/include/c++/10/pstl/glue_algorithm_defs.h:13,
from /usr/include/c++/10/algorithm:74,
from /usr/include/x86_64-linux-gnu/c++/10/bits/stdc++.h:65,
from Main.cpp:1:
/usr/include/c++/10/bits/stl_vector.h:794:7: note: candidate: 'void std::vector<_Tp, _Alloc>::assign(std::initializer_list<_Tp>) [with _Tp = int; _Alloc = std::allocator<int>]'
794 | assign(initializer_list<value_type> __l)
| ^~~~~~
/usr/include/c++/10/bits/stl_vector.h:794:43: note: no known conversion for argument 1 from 'int' to 'std::initializer_list<int>'
794 | assign(initializer_list<value_type> __l)
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~
Main.cpp: In member function 'int SEGT::_query(int, int, int, int, int)':
Main.cpp:37:38: error: no matching function for call to 'SEGT::query(int, int&, int&, int&, int&)'
37 | return max(query(ind*2,l,mid,ql,qr) , query(ind*2+1,mid+1,r,ql,qr));
| ^
Main.cpp:40:6: note: candidate: 'int SEGT::query(int, int)'
40 | int query(int l , int r){
| ^~~~~
Main.cpp:40:6: note: candidate expects 2 arguments, 5 provided
Main.cpp:37:69: error: no matching function for call to 'SEGT::query(int, int, int&, int&, int&)'
37 | return max(query(ind*2,l,mid,ql,qr) , query(ind*2+1,mid+1,r,ql,qr));
| ^
Main.cpp:40:6: note: candidate: 'int SEGT::query(int, int)'
40 | int query(int l , int r){
| ^~~~~
Main.cpp:40:6: note: candidate expects 2 arguments, 5 provided
Main.cpp: In function 'void solve()':
Main.cpp:49:56: error: no type named 'value_type' in 'struct std::greater<int>'
49 | priority_queue < pair < int , int > , greater < int > > q[n+1];
| ^
Main.cpp:49:56: error: template argument 3 is invalid
Main.cpp:54:13: error: request for member 'push' in 'q[lis[i]]', which is of non-class type 'int'
54 | q[lis[i]].push({arr[i],i});
| ^~~~
Main.cpp:59:14: error: request for member 'size' in 'q[i]', which is of non-class type 'int'
59 | while(q[i].size()){
| ^~~~
Main.cpp:60:34: error: request for member 'front' in 'q[i]', which is of non-class type 'int'
60 | pair < int , int > cur = q[i].front();
| ^~~~~
Main.cpp:61:9: error: request for member 'pop' in 'q[i]', which is of non-class type 'int'
61 | q[i].pop();
| ^~~
Main.cpp:63:17: error: request for member 'size' in 'q[(i - 1)]', which is of non-class type 'int'
63 | while(q[i-1].size()){
| ^~~~
Main.cpp:64:38: error: request for member 'front' in 'q[(i - 1)]', which is of non-class type 'int'
64 | pair < int , int > cand = q[i-1].front();
| ^~~~~
Main.cpp:65:12: error: request for member 'pop' in 'q[(i - 1)]', which is of non-class type 'int'
65 | q[i-1].pop();
| ^~~
Main.cpp:77:11: error: request for member 'push' in 'q[(i - 1)]', which is of non-class type 'int'
77 | q[i-1].push(itr);
| ^~~~