Which of the following data structures allows both addition and deletion of…

2017

Which of the following data structures allows both addition and deletion of items from either end?

  1. A.

    Double Ended Queue

  2. B.

    Queue

  3. C.

    Priority Queue

  4. D.

    Stack

Attempted by 377 students.

Show answer & explanation

Correct answer: A

The correct option is A. A Double Ended Queue (commonly known as a Deque) is a generalized linear data structure that permits insertions and deletions from both the front and the rear ends, unlike a standard queue which follows strict FIFO rules.

Explore the full course: Niacl Ao It Specialist