joi2019_ho_t4.cpp: In function 'int main()':
joi2019_ho_t4.cpp:26:24: error: expected primary-expression before ')' token
for(int i=0; i<2*N; i+){
^
joi2019_ho_t4.cpp:28:7: error: invalid types 'int[int]' for array subscript
s[i]=max(0, C[i].first);
^
joi2019_ho_t4.cpp:28:26: error: no matching function for call to 'max(int, long long int&)'
s[i]=max(0, C[i].first);
^
In file included from /usr/include/c++/7/deque:60:0,
from /usr/include/c++/7/queue:60,
from joi2019_ho_t4.cpp:2:
/usr/include/c++/7/bits/stl_algobase.h:219:5: note: candidate: template<class _Tp> constexpr const _Tp& std::max(const _Tp&, const _Tp&)
max(const _Tp& __a, const _Tp& __b)
^~~
/usr/include/c++/7/bits/stl_algobase.h:219:5: note: template argument deduction/substitution failed:
joi2019_ho_t4.cpp:28:26: note: deduced conflicting types for parameter 'const _Tp' ('int' and 'long long int')
s[i]=max(0, C[i].first);
^
In file included from /usr/include/c++/7/deque:60:0,
from /usr/include/c++/7/queue:60,
from joi2019_ho_t4.cpp:2:
/usr/include/c++/7/bits/stl_algobase.h:265:5: note: candidate: template<class _Tp, class _Compare> constexpr const _Tp& std::max(const _Tp&, const _Tp&, _Compare)
max(const _Tp& __a, const _Tp& __b, _Compare __comp)
^~~
/usr/include/c++/7/bits/stl_algobase.h:265:5: note: template argument deduction/substitution failed:
joi2019_ho_t4.cpp:28:26: note: deduced conflicting types for parameter 'const _Tp' ('int' and 'long long int')
s[i]=max(0, C[i].first);
^
In file included from /usr/include/c++/7/algorithm:62:0,
from joi2019_ho_t4.cpp:3:
/usr/include/c++/7/bits/stl_algo.h:3462:5: note: candidate: template<class _Tp> constexpr _Tp std::max(std::initializer_list<_Tp>)
max(initializer_list<_Tp> __l)
^~~
/usr/include/c++/7/bits/stl_algo.h:3462:5: note: template argument deduction/substitution failed:
joi2019_ho_t4.cpp:28:26: note: mismatched types 'std::initializer_list<_Tp>' and 'int'
s[i]=max(0, C[i].first);
^
In file included from /usr/include/c++/7/algorithm:62:0,
from joi2019_ho_t4.cpp:3:
/usr/include/c++/7/bits/stl_algo.h:3468:5: note: candidate: template<class _Tp, class _Compare> constexpr _Tp std::max(std::initializer_list<_Tp>, _Compare)
max(initializer_list<_Tp> __l, _Compare __comp)
^~~
/usr/include/c++/7/bits/stl_algo.h:3468:5: note: template argument deduction/substitution failed:
joi2019_ho_t4.cpp:28:26: note: mismatched types 'std::initializer_list<_Tp>' and 'int'
s[i]=max(0, C[i].first);
^
joi2019_ho_t4.cpp:32:7: error: invalid types 'int[int]' for array subscript
s[i]=i/2;
^
joi2019_ho_t4.cpp:33:28: error: no matching function for call to 'min(int, long long int&)'
e[i]=min(N-1, C[i].first);
^
In file included from /usr/include/c++/7/deque:60:0,
from /usr/include/c++/7/queue:60,
from joi2019_ho_t4.cpp:2:
/usr/include/c++/7/bits/stl_algobase.h:195:5: note: candidate: template<class _Tp> constexpr const _Tp& std::min(const _Tp&, const _Tp&)
min(const _Tp& __a, const _Tp& __b)
^~~
/usr/include/c++/7/bits/stl_algobase.h:195:5: note: template argument deduction/substitution failed:
joi2019_ho_t4.cpp:33:28: note: deduced conflicting types for parameter 'const _Tp' ('int' and 'long long int')
e[i]=min(N-1, C[i].first);
^
In file included from /usr/include/c++/7/deque:60:0,
from /usr/include/c++/7/queue:60,
from joi2019_ho_t4.cpp:2:
/usr/include/c++/7/bits/stl_algobase.h:243:5: note: candidate: template<class _Tp, class _Compare> constexpr const _Tp& std::min(const _Tp&, const _Tp&, _Compare)
min(const _Tp& __a, const _Tp& __b, _Compare __comp)
^~~
/usr/include/c++/7/bits/stl_algobase.h:243:5: note: template argument deduction/substitution failed:
joi2019_ho_t4.cpp:33:28: note: deduced conflicting types for parameter 'const _Tp' ('int' and 'long long int')
e[i]=min(N-1, C[i].first);
^
In file included from /usr/include/c++/7/algorithm:62:0,
from joi2019_ho_t4.cpp:3:
/usr/include/c++/7/bits/stl_algo.h:3450:5: note: candidate: template<class _Tp> constexpr _Tp std::min(std::initializer_list<_Tp>)
min(initializer_list<_Tp> __l)
^~~
/usr/include/c++/7/bits/stl_algo.h:3450:5: note: template argument deduction/substitution failed:
joi2019_ho_t4.cpp:33:28: note: mismatched types 'std::initializer_list<_Tp>' and 'int'
e[i]=min(N-1, C[i].first);
^
In file included from /usr/include/c++/7/algorithm:62:0,
from joi2019_ho_t4.cpp:3:
/usr/include/c++/7/bits/stl_algo.h:3456:5: note: candidate: template<class _Tp, class _Compare> constexpr _Tp std::min(std::initializer_list<_Tp>, _Compare)
min(initializer_list<_Tp> __l, _Compare __comp)
^~~
/usr/include/c++/7/bits/stl_algo.h:3456:5: note: template argument deduction/substitution failed:
joi2019_ho_t4.cpp:33:28: note: mismatched types 'std::initializer_list<_Tp>' and 'int'
e[i]=min(N-1, C[i].first);
^
joi2019_ho_t4.cpp:37:20: error: invalid types 'int[int]' for array subscript
if(i<2*N-1&&s[i+1]>dn) con[i]=(un++)*2;
^
joi2019_ho_t4.cpp:38:25: error: invalid types 'int[int]' for array subscript
else if(i<2*N-1&&s[i+1]>un) con[i]=(dn++)*2+1;
^
joi2019_ho_t4.cpp:21:7: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
scanf("%d", &N);
~~~~~^~~~~~~~~~
joi2019_ho_t4.cpp:22:32: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
for(int i=0; i<N*2; i++) scanf("%lld%lld", &C[i].first, &C[i].second);
~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~