this repo has no description
at develop 862 B view raw
1/*** 2!Test 3expected: 4- !Result 5 solution: !Solution 6 firstin: 1 7 lastin: 1 8- !Result 9 solution: !Solution 10 firstin: 1 11 lastin: 2 12- !Result 13 solution: !Solution 14 firstin: 2 15 lastin: 2 16- !Result 17 solution: !Solution 18 firstin: 1 19 lastin: 3 20- !Result 21 solution: !Solution 22 firstin: 2 23 lastin: 3 24- !Result 25 solution: !Solution 26 firstin: 3 27 lastin: 3 28***/ 29 30% Regression test for a problem with the "linear" MiniZinc redefinitions. 31% The signature of array_var_bool_element/3 in the redefintions was 32% incorrect leading to an internal error in mzn2fzn. 33 34int: n=3; 35array[1..n] of var 1..n: succ; 36array[1..n] of var bool: ins = [ succ[i] != i | i in 1..n]; 37var 1..n+1: firstin; 38constraint firstin == min([ n+1 + bool2int(ins[i])*(i-n-1) | i in 1..n]); 39var 1..n: lastin; 40 41constraint ins[lastin]; 42 43solve satisfy; 44 45output ["Ok\n"];