A queue is a data structure that follows the FIFO (first in, first out) principle.
Optional
Clears the queue
Removes the first item in the queue and returns it
The first item in the queue
Adds an item to the end of the queue
The item to add to the queue
Retrieves the first item in the queue without removing it
Removes an item from the queue
The item to remove from the queue
A queue is a data structure that follows the FIFO (first in, first out) principle.