1
0
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.

7 lines
256 B
MiniZinc

predicate fzn_sum_pred(var int: i, array[int] of set of int: sets,
array[int] of int: cs, var int: s) =
let {
array[index_set(sets)] of int: sums = [ sum(i in sets[j])(cs[i]) | j in index_set(sets) ];
} in sums[i] = s;