Question 44

Computer Awareness Data Structure Easy

Match List-I with List-II. $$\begin{array}{|c|l|} \hline \textbf{List-I (Algorithm/Application)} & \textbf{List-II (Data Structure Used)} \\ \hline (A)\ BFS & (I)\ Stack \\ \hline (B)\ DFS & (II)\ B Tree \\ \hline (C)\ Heap\ Sort & (III)\ Priority\ Queue \\ \hline (D)\ Storage\ on\ secondary\ storage\ devices & (IV)\ B\ Queue \\ \hline \end{array}$$

(A) (A)-(IV), (B)-(I), (C)-(III), (D)-(II)
(B) (A)-(I), (B)-(III), (C)-(II), (D)-(IV)
(C) (A)-(I), (B)-(II), (C)-(IV), (D)-(III)
(D) (A)-(III), (B)-(IV), (C)-(I), (D)-(II)
View Dynamic Solution & Explanation
Correct Solution: Option A

Step-by-step Solution:

Solution

We are asked to match the algorithms/applications with the data structures they commonly use.

Step 1: Analyze Each Pair

  • BFS (Breadth-First Search): Uses a queue to keep track of nodes at the current level. → Matches with (IV) B Queue.
  • DFS (Depth-First Search): Uses a stack (explicit or call stack) to explore nodes deeply. → Matches with (I) Stack.
  • Heap Sort: Requires a priority queue or heap data structure for efficient sorting. → Matches with (III) Priority Queue.
  • Storage on secondary storage devices: Often implemented using B-trees for indexing. → Matches with (II) B Tree.

Step 2: Match List-I with List-II

(A)-(IV), (B)-(I), (C)-(III), (D)-(II)

Answer: Option A