The Deque
class is a "double-ended Queue," and not to be confused with the word "dequeue." The double-ended queue allows one to add values to the front or rear of the queue, and allows for values to be removed from the front or rear of the queue.
For the Deque
class write:
Deque
constructoradd_front(item)
add_rear(item)
remove_front()
remove_rear()
size()
is_empty()