Queues

0.0(0)
studied byStudied by 0 people
learnLearn
examPractice Test
spaced repetitionSpaced Repetition
heart puzzleMatch
flashcardsFlashcards
Card Sorting

1/9

encourage image

There's no tags or description

Looks like no tags are added yet.

Study Analytics
Name
Mastery
Learn
Test
Matching
Spaced

No study sessions yet.

10 Terms

1
New cards

Queue

An ordered collection where items are added at one end (rear/tail) and removed from the other end (front/head), following the principle of First In - First Out (FIFO).

2
New cards

enqueue

The operation of adding an element to the rear of the queue.

3
New cards

dequeue

The operation of removing an element from the front of the queue.

4
New cards

Bounded Queue

A queue that is limited to a fixed number of items, with a set capacity that cannot be changed after creation.

5
New cards

Circular Queue

A type of bounded queue where the front and rear indexes slide, allowing the structure to wrap around when it reaches the end.

6
New cards

FIFO

First In, First Out; a principle stating that the first element added to a queue will be the first to be removed.

7
New cards

isEmpty()

A method that checks whether the queue is empty, returning a boolean value.

8
New cards

size()

A method that returns the number of items currently in the queue.

9
New cards

peek()

A method that allows checking the front item of the queue without removing it.

10
New cards

Double-ended Queue (Deque)

A data structure that allows insertion and deletion of elements from both ends.