Problem pythonlist
User Roucy
Submission Time 2025-06-18 10:14:34
Score 0
Max Time N/A
Max Memory N/A

Compile Error

pythonlist.cpp: In function ‘int main()’:
pythonlist.cpp:9:11: error: no matching function for call to ‘std::deque<int>::size(int)’
9 | dq.size(5)
| ^
In file included from /usr/include/c++/9/deque:67,
from /usr/include/x86_64-linux-gnu/c++/9/bits/stdc++.h:68,
from pythonlist.cpp:1:
/usr/include/c++/9/bits/stl_deque.h:1298:7: note: candidate: ‘std::deque<_Tp, _Alloc>::size_type std::deque<_Tp, _Alloc>::size() const [with _Tp = int; _Alloc = std::allocator<int>; std::deque<_Tp, _Alloc>::size_type = long unsigned int]’
1298 | size() const _GLIBCXX_NOEXCEPT
| ^~~~
/usr/include/c++/9/bits/stl_deque.h:1298:7: note: candidate expects 0 arguments, 1 provided
pythonlist.cpp:13:14: error: ‘Empty’ was not declared in this scope
13 | dq.pop_back(Empty);
| ^~~~~
pythonlist.cpp:15:5: error: expected ‘(’ before ‘else’
15 | i