-
Notifications
You must be signed in to change notification settings - Fork 9
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Lecture "Backtracking algorithms", exercise 1 #35
Comments
|
We (me and Tommaso Battisti) have tried to solve the problem without adding the set part in To see the efficiency of the function we have used a list
|
I tried to implement a similar logic to that of dynamic programming algorithms using a dictionary. I could not test its efficiency accurately and therefore I suppose it's probably incorrect but I thought I would post it anyway.
|
@Postitisnt you have to do @chloeppd, it is correct to follow the dynamic programming approach, but you have to change the signature of the function by passing your "notebook" to it, avoiding creating it every time at the beginning of the function, otherwise it will be always overwritten with a new object at every recursive step. |
Propose some variation to the implementation of the peg solitaire exercise to make it more efficient – in particular, avoiding unsuccessful configurations if they have been previously encountered while looking for a solution.
The text was updated successfully, but these errors were encountered: