1.

What happens when the backtracking algorithm reaches a complete solution?(a) It backtracks to the root(b) It continues searching for other possible solutions(c) It traverses from a different route(d) Recursively traverses through the same routeThis question was addressed to me by my school teacher while I was bunking the class.This is a very interesting question from Backtracking in chapter Backtracking of Data Structures & Algorithms II

Answer»

The CORRECT ANSWER is (B) It continues searching for other possible solutions

Easiest EXPLANATION - When we reach a final solution using a backtracking algorithm, we either STOP or continue searching for other possible solutions.



Discussion

No Comment Found

Related InterviewSolutions