Queue
Queue: Queue, ~Queue, push, pop, first, size, empty
struct Queue<T>
First-in-first-out data structure
Queue
Queue()Initialize an empty Queue
~Queue
~Queue()Frees all nodes.
push
void push(T value)Add to the back of the queue
pop
T pop()Retrieve and remove head of the queue
first
T& first()Access element in the front of the queue
size
int size()Returns the number of elements in the queue
empty
bool empty()Check if queue is empty
struct Node<T>
One element of a queue.
Node
Node(T val)Initializes a node holding the given value.