GATE DA 2024 Q44: BFS versus DFS expansions to reach state 6
- Artificial Intelligence
- 2 marks
- MCQ
- −2/3 if wrong
Question
Consider a state space where the start state is number 1. The successor function for the state numbered n returns two states numbered n+1 and n+2. Assume that the states in the unexpanded state list are expanded in the ascending order of numbers and the previously expanded states are not added to the unexpanded state list.
Which ONE of the following statements about breadth-first search (BFS) and depth-first search (DFS) is true, when reaching the goal state number 6?
Try it: multiple choice: exactly one correct option
Show answer and explanation
Answer: C (official GATE 2024 final answer key)
Concept used: Simulate BFS (queue) and DFS (stack) with duplicate detection.
First step: Because the smallest-numbered state is always expanded first, both searches expand states 1, 2, 3, 4, 5 before reaching 6.
Full step-by-step solution
Detailed working, common mistakes and linked mock tests will be available with a free GATEiit account. Log-in is coming soon.
Share this question
Source: official GATE 2024 DA question paper and final answer key, organised by IISc Bangalore. Question paper · Answer key
More Artificial Intelligence PYQs
- 2026 · Q13Which search algorithm is not uninformed
- 2026 · Q14Incorrect first-order logic translation
- 2026 · Q24What X entails Y means
- 2026 · Q30Best MAX strategy in a two-level minimax tree
- 2026 · Q38Logical form of 'creative people succeed iff disciplined'
- 2026 · Q48Which first-order logic statements are not valid