Waiting for answer This question has not been answered yet. You can hire a professional tutor to get the answer.

QUESTION

Recursive backtracking Suppose I want to burn some songs onto a 650MB CD (some people still do!) and I have a list of song tracks of various sizes. I...

Recursive backtracking

Suppose I want to burn some songs onto a 650MB CD (some people still do!) and I have a list of song tracks of various sizes.

I want to fill up as much of my CD as I can. I can use a recursive backtracking strategy to find a subset of the song tracks that optimally fills my CD (that is, with the least space left unfilled). You should recognise this problem as a version of the.Here is the basic recursive backtracking strategy:

(a) What should an input instance for this problem consist of?

(b) Given an input instance, what should be returned as a valid solution for the problem?

(c) Given a valid solution, what is the measure to be used to determine if it is better than some other solution?

(d) What basic strategy can be used to prune the recursion tree?

(e) Using your answers to the previous parts of this question as a basis, write down a recursive back-tracking algorithmthat solves the . You can write the code for your algorithmusing normal Python syntax, or you can use pseudocode.

Show more
LEARN MORE EFFECTIVELY AND GET BETTER GRADES!
Ask a Question