What is backtracking?
Backtracking is a general algorithmic technique used to find solutions to problems incrementally by exploring all possible options and abandoning (or "backtracking") those that do not lead to a solution. It is particularly useful for solving combinatorial problems and constraint satisfaction problems.