Queues (Cambridge International A-Level Computer Science)
Exam board Cambridge International · A-LevelUpdated 2025-05-16
Implementing a queue
How do you program a queue?
-
A queue is a linear ADT that follows the First In, First Out (FIFO) principle:
- Enqueue: Add item to the back
- Dequeue: Remove item from the front
- Peek/front: Look at the front item without removing
- isEmpty / isFull: Check queue status
-
Assuming a record-based circular queue implementation:
Enqueue
Dequeue
isEmpty / isFull
Find (linear search)
Python
Java
Was this revision note helpful?
Build on this topic