I have a funny little problem when presented with a logical suggestion:
Rule 1. A, B and C are unique, and are numbers from 1 to 3 (so every number is used).
Rule 2. B < 2
Rule 3. C > 2
Now (assuming that this quick example that I just came up with really checks: P), it's easy to see
A = 2
B = 1
C = 3
But this is a very contrived example.
How about if you have 20 (or ten thousand) rules and they overlap. Suppose there is a valid single answer, and you somehow have access to the rules (say, this is a list of predicates).
Is there a pleasant, general, intuitive solution? I know that Prolog can solve the problem with some libraries, but my attempts have been futile. I know that I can just go over all the permutations in a range and then manually check if they comply with the rules. But that seems pretty lame.