Debian Codegraph @

tests/spec/unit/general/test_lb_ub_dom_int.mzn

raw
1 /***
2 !Test
3 expected: !Result
4 status: SATISFIED
5 solution: !Solution
6 test_1: 3
7 test_2: 3
8 test_3: 1
9 test_4: 10
10 ***/
11
12 var 1..10: x;
13
14 var -100..100: test_1 :: add_to_output = lb(3);
15 var -100..100: test_2 :: add_to_output = ub(3);
16
17 var -100..100: test_3 :: add_to_output = lb(x);
18 var -100..100: test_4 :: add_to_output = ub(x);
19
20 constraint dom(x) = 1..10;
21
22 solve satisfy;
23
24 output [
25 "test_1 = ", show(test_1), ";\n",
26 "test_2 = ", show(test_2), ";\n",
27 "test_3 = ", show(test_3), ";\n",
28 "test_4 = ", show(test_4), ";\n"
29 ];