CPSolver.Examples.Euler43 (Fixpoint v0.10.2)
Summary
Functions
int: n = 10; array[1..n] of var 0..9: x; array[int] of int: primes = [2,3,5,7,11,13,17]; solve satisfy; constraint all_different(x) / forall(i in 2..8) (
Functions
int: n = 10; array[1..n] of var 0..9: x; array[int] of int: primes = [2,3,5,7,11,13,17]; solve satisfy; constraint all_different(x) / forall(i in 2..8) (
(100*x[i] + 10*x[i+1] + x[i+2]) mod primes[i-1] = 0
) ; output [ show(x)," "];