All of the solutions for the zebra puzzle have a variable for each of the properties and a domain with the possible values. For instance A for Nationalities, B for pets, ...
Ai with i = 1..5 and the domain for example {Dutch, Spanish, Italian, French, English}
As I've seen in the n-queens puzzle, there can always be multiple representations for a constraint problem. What could be alternative representations for the zebra puzzle?
For example, I was thinking about following representation:
- HouseOne indices 1..4 with domain {1,2,3,4,5}
- HouseTwo indices 1..4 with domain {1,2,3,4,5}
- HouseThree indices 1..4 with domain {1,2,3,4,5}
- HouseFour indices 1..4 with domain {1,2,3,4,5}
- HouseFive indices 1..4 with domain {1,2,3,4,5}
Could this work?