# Which Is a Linear Data Structure McQ?

//

Angela Bailey

Linear data structure is a fundamental concept in computer science and is widely used in various applications. In this article, we will explore the concept of linear data structures and discuss multiple-choice questions (MCQs) related to them. So, let’s dive in!

## What is a Linear Data Structure?

A linear data structure is a collection of elements where each element has a direct successor and predecessor, except for the first and last elements. In simple terms, it represents a sequence of elements arranged in a specific order.

Common examples of linear data structures include arrays, linked lists, stacks, and queues. These structures are used to store and manipulate data efficiently.

## Multiple-Choice Questions (MCQs)

### 1. Which of the following is NOT an example of a linear data structure?

• a) Array
• c) Tree
• d) Stack

The tree is not considered a linear data structure because its elements are not arranged in a sequential order. Instead, they are organized hierarchically.

### 2. Which data structure follows the Last-In-First-Out (LIFO) principle?

• a) Array
• c) Queue
• d) Stack

A stack is designed to follow the LIFO principle, where the last element inserted is the first one to be removed. It can be visualized as a stack of plates, where you can only remove the top plate.

### 3. Which of the following data structures is used for breadth-first traversal?

• a) Array
• c) Queue
• d) Stack

Breadth-first traversal involves exploring all the neighbors of a node before moving to its children. This approach is best implemented using a queue data structure.

• a) O(1)
• b) O(n)
• c) O(log n)
• d) O(n^2)