This repository has been archived on 2025-03-06. You can view files and clone it, but cannot push or open issues or pull requests.
dekker-phd-thesis/assets/listing/back_knapsack.fzn
2021-07-14 20:42:24 +10:00

11 lines
307 B
MiniZinc

var 0..1: selection_0;
var 0..1: selection_1;
var 0..1: selection_2;
var 0..175: total_joy:: is_defined_var;
constraint int_lin_le([32,8,40], [selection_0,selection_1,selection_2], 44);
constraint int_lin_eq(
[63,12,100,-1],
[selection_0,selection_1,selection_2,total_joy],
0
);
solve maximize total_joy;