Provides a doubled ended queue abstract data type. This is a first in first out data structure which can be added to or taken from at either end.
procedure(push_sub), public, deferred :: pushleft | Add an item to the left end of the data structure (equivalent to push on a queue) |
procedure(push_sub), public, deferred :: pushright | Add an item to the right end of the data structure |
procedure(pop_func), public, deferred :: popleft | Remove and return the item from the left end of the data structure |
procedure(pop_func), public, deferred :: popright | Remove and return the item from the right end of the data structure (equivalent to pop on a queue) |
procedure(peek_func), public, deferred :: peekleft | Return, but do not remove, the item at the left end of the data structure |
procedure(peek_func), public, deferred :: peekright | Return, but do not remove, the item at the left end of the data structure (equivalent to peek on a queue) |
An abstract data type representing the double ended queue data structure. Rather than just pushing items to one end (the "left end") and popping them from the other (the "right end"), items can be pushed or popped to/from either the right or the left.