The General Pattern
Understand the general pattern behind backtracking algorithms and how to use recursive decision-making to build solutions satisfying specific constraints. Learn to design efficient recursive algorithms by managing past decisions and trying all possibilities to solve complex problems systematically.
We'll cover the following...
We'll cover the following...
Characteristics of backtracking algorithms
Backtracking algorithms are commonly used to make a sequence of decisions, with the goal of building a recursively defined structure satisfying certain constraints. Often (but not always), this goal structure is itself a sequence. For example:
- In the queens problem, the goal is a sequence of queen