In this post we solve another logic puzzle deriving rules from the puzzle and stating them in Prolog. And this time it is a rather famous puzzle one: the Zebra puzzle (also called Einstein riddle/puzzle).
There are four researchers: Ainsley, Madeline, Sophie and Theodore. The goal is to find out their sports competition discipline, birth year and research interests (while knowing that each of the mentioned attributes is different amongst them). In order so solve the puzzle, a couple of hints is provided from which the solution can be derived.
Eilen, Ada, Verena and Jenny participated in a painting competition. Find out who painted which subject and who took which place in the competition, using the hints provided.
There are 4 students: Carrie, Erma, Ora und Tracy. Each has one scholarship and one major subject they study. The goal is to find out which student has which scholarship and studies which subject (with all scholarships and majors being different from each other) from the hints provided.
In this post we are implementing a Hidoku solver (Hidoku is yet another fine number puzzle) that uses a depth first search, branch cutting, limited (intelligent) successor generation and some automatic simplification. Usually, a Hidoku is a quadratic board consisting of n x n fields - but rectangular or other forms would be possible as well. With each Hidoku, some fields are already pre-filled with numbers at the beginning. The game goal is to fill in all other numbers so that an ascending number queue is built: each number has to be adjacent to it's successor, with adjacent meaning in an adjacent horizontal, vertical or diagonal field.
The checkerboard puzzle or draught board puzzle (also called Krazee Checkerboard Puzzle, Banzee Island checkerboard puzzle, Zebas puzzle, etc.) is a mutilated chessboard problem, which further is a tiling puzzle/dissection puzzle. Hence, the core problem is similar to the one of solving the well known Tangram, which some of you might be familiar with. The … Continue reading Draught board puzzle / checkerboard puzzle solver in Python
The magic number board puzzle is yet another equation puzzle (similar to the first equation puzzle or Jodici) - but has a notable larger solution space. The magic number board is a quadratic board, consisting of 5x5 = 25 fields, which are organized as 5 horizontal rows and 5 vertical columns. Each field should contain … Continue reading Magic number board puzzle solver in Python