Deque Interface
Deque Interface - Doubly ended queue is the concept of data structure in programming. Deque also called Doubly ended queue. Deque is extents Queue interface and define the structure of Doubly ended queue. Deque defines the functionality to delete data from both side first and last node. This interface defines methods to access the elements at both ends of the deque. A list of methods are below : boolean add(E e) - Inserts the specified element into the queue represented by this deque (in other words, at the tail of this deque) if it is possible to do so immediately without violating capacity restrictions, returning true upon success and throwing an IllegalStateException if no space is currently available. void addFirst(E e) - Inserts the specified element at the front of this deque if it is possible to do so immediately without ...