Problem shamelessad3
User DuckyKayden
Submission Time 2025-12-10 15:21:45
Score 0
Max Time N/A
Max Memory N/A

Compile Error

shamelessad3.cpp: In function ‘int32_t main()’:
shamelessad3.cpp:26:34: error: ‘arr’ was not declared in this scope
26 | while(mono.top() != n && arr[mono.top()] >= a[i]) {
| ^~~
shamelessad3.cpp:30:19: error: no matching function for call to ‘std::stack<long long int>::push()’
30 | mono.push();
| ^
In file included from /usr/include/c++/9/stack:61,
from /usr/include/x86_64-linux-gnu/c++/9/bits/stdc++.h:89,
from shamelessad3.cpp:1:
/usr/include/c++/9/bits/stl_stack.h:233:7: note: candidate: ‘void std::stack<_Tp, _Sequence>::push(const value_type&) [with _Tp = long long int; _Sequence = std::deque<long long int, std::allocator<long long int> >; std::stack<_Tp, _Sequence>::value_type = long long int]’
233 | push(const value_type& __x)
| ^~~~
/usr/include/c++/9/bits/stl_stack.h:233