Tree traversal (backtracking)
In the preceding section we considered several problems of a similar type: “generate all the elements of some set A”. The scheme used to solve these problems was the following one: A linear ordering on A was imposed and a procedure to generate the next element of A (according to that order) was described. Sometimes this scheme cannot be applied directly. In this chapter, we consider another useful approach that allows us to generate all elements of some set. It is called “backtracking” or “tree traversal”.
KeywordsPosition Tree Current Position Knapsack Problem Diagonal Line Boolean Variable
Unable to display preview. Download preview PDF.