Recall & Review
beginner Click to reveal answer
What is backtracking in simple terms?
Backtracking is a way to solve problems by trying out choices one by one and going back if a choice does not lead to a solution.
beginner Click to reveal answer
What does a decision tree represent in backtracking?
A decision tree shows all possible choices and paths the algorithm can take to find a solution.
intermediate Click to reveal answer
How does backtracking use recursion?
Backtracking uses recursion to explore each choice deeply and return to previous steps when needed.
intermediate Click to reveal answer
Why is backtracking efficient for problems like puzzles or combinations?
Because it stops exploring paths early when it knows they won't work, saving time.
advanced Click to reveal answer
What is the role of 'pruning' in backtracking?
Pruning means cutting off paths in the decision tree that cannot lead to a solution to avoid unnecessary work.
What happens when backtracking reaches a dead end?
✗ Incorrect
Backtracking returns to the previous step to try a different choice when a path fails.
In a decision tree for backtracking, what do the branches represent?
✗ Incorrect
Branches show the different choices the algorithm can make at each step.
Which problem is best solved by backtracking?
✗ Incorrect
Backtracking is great for exploring all subsets or combinations.
What is the main advantage of using backtracking?
✗ Incorrect
Backtracking prunes paths that won't work, making exploration efficient.
How does backtracking relate to recursion?
✗ Incorrect
Backtracking typically uses recursion to explore each choice deeply.
Explain how backtracking explores a problem using a decision tree.
Think about how you try paths in a maze and go back if blocked.
You got /4 concepts.
Describe the role of pruning in backtracking and why it helps.
Imagine stopping a search when you know it won't work.
You got /4 concepts.
