{{Data structure}}
[[File:Fifo.gif|frame|right|Illustration of FIFO behavior]]

;Task:
Implement a FIFO queue.

Elements are added at one side and popped from the other in the order of insertion.


Operations:
* &nbsp; push   &nbsp; (aka ''enqueue'') &nbsp; - add element
* &nbsp; pop    &nbsp; &nbsp; (aka ''dequeue'') &nbsp; - pop first element
* &nbsp; empty  &nbsp; - return truth value when empty


Errors:
* &nbsp; handle the error of trying to pop from an empty queue (behavior depends on the language and platform)


;See:
* &nbsp; [[Queue/Usage]] &nbsp; for the built-in FIFO or queue of your language or standard library.


{{Template:See also lists}}
<br><br>
