I was scrolling through Instagram reels when something caught my eye:
This cute object is Kanoodle, a puzzle in which you have to fit coloured plastic pieces into a rectangle.
The game starts by placing at least one piece randomly within the available space and then trying to solve it.
My idea was to create an exercise where the user declares that the puzzle is impossible to solve or provides a possible configuration that is one of the solutions.
Let me know what you think!
That could be interesting. I think we’d need to stick to the original board size to keep if solvable in a reasonable amount of time!
I tried to find out a little more about the subject.
I found Donald E. Knuth’s paper discussing the Dancing Links technique and the Algorithm X used to solve sub-problems in the Exact Cover field.
I tried making a small demo in Elixir without this algorithm, and I must say that, although it works well for almost completed puzzles, brute forcing is not the right method to use for an empty one. ![]()
This exercise could be a perfect candidate for inclusion in the Hard category.
Would anyone like to give me their opinion on this?
Here is the link to the paper:
I haven’t read the paper but would suggest if a specific algorithm is “essential” for solving this exercise, then the exercise should make the algorithm easy to find and understand.
If the algorithm is not reasonably understandable without, say, a background in higher mathes, I’d be inclined to vote against this as an exercise.
