# Basic CS-Data Structures [3i Infotech Placement]: Sample Questions 43 - 45 of 52

Glide to success with Doorsteptutor material for competitive exams : get questions, notes, tests, video lectures and more- for all subjects of your exam.

## Question 43

Data Structures

### Question

MCQ▾

In tree construction which is the suitable efficient data structure?

Choice (4)

a.

Queue

b.

c.

Stack

d.

Array

b.

### Explanation

• A linked list is a sequence of data structures connected to each other via links.
• The second most-used data structure after array.

Important terms to understand the concept of Linked List:

• Every link of a linked list stores a data called an element
• Next

## Question 44

Data Structures
Edit

### Write in Short

What is Minimum number of queues needed to implement the priority queue?

### Explanation

• 2 queues would be needed.
• One queue stores the data and creates one more queue.
• The second queue stores the priority in place of data- priority the program would check and process.

## Question 45

Data Structures
Edit

### Describe in Detail

Essay▾

Does the minimum spanning tree of a graph give the shortest distance between any 2 specified nodes?

### Explanation

• No, the minimum spanning tree is not guaranteed to give the shortest distance between any 2 specified nodes.
• By definition the min spanning tree doesn՚t have redundant connections and hence no shortcuts which the full graph might have.

Minimum spanning Tree:

• A subset of the edges of a connected graph.
• A graph can have many spanning trees.
• Minimum spanning tree is the spanning tree where the cost is minimum among all the spanning trees- with cost defined as weight of vertices
• Graph can have many minimum spanning trees.
• Direct application in the design of networks.
• Used in algorithms-
• Approximating the travelling salesman problem
• Multi-terminal minimum cut problem
• Minimum-cost weighted perfect matching

Developed by: