Chapter 29

Queues

Abstract

Queue is a fancy name for a waiting line. The basic idea is that things enter one end of the queue (the tail), wait for awhile, and get serviced at the other end of the queue (the head). This is what happens to people in a grocery store checkout line or to DVDs in a Netflix list.

Keywords

Dequeue

Enqueue

FIFO

LIFO

Netflix

Priority queues

Rearrangement

Waiting line

Queue is a fancy name for a waiting line. The basic idea is that things enter one end of the queue (the tail), wait for awhile and get serviced at the other end of the queue (the head). This is what happens to people in a grocery store checkout line or to DVDs in your Netflix list.

Each element has a position in the queue, so we know that a table to model ...

Get Joe Celko's SQL for Smarties, 5th Edition now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.