[gecode-users] Question about one type of constraint

Chd Orti richard.portell at gmail.com
Thu Oct 16 10:52:06 CEST 2014


Hello,
I have an array (size 10) of positive integers which can also take the
value 0;
I have a constraint on the sum of these numbers for example 10;
Here is a solution for example :
1 2 0 0 5 1 0 0 0 1
I want to add a constraint : the sum of the 2 first integers with value
different to 0 equals 4.
How could I do that?
Cheers,
Richard
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.gecode.org/pipermail/users/attachments/20141016/3f1385e9/attachment-0001.html>


More information about the users mailing list