[ library(ic) | The ECLiPSe Libraries | Reference Manual | Alphabetic Index ]

labeling(+Vars)

Instantiates all variables in a list to elements of their domains.
Vars
A list of integer IC variables or integers

Description

Simple predicate for instantiating a list of integer IC variables to elements of their domains. (Integers are also allowed in the list; they are effectively ignored.) The variables are instantiated in the order in which they appear in the list; the implementation is essentially:

        labeling([]).
        labeling([Var|Rest]) :-
            indomain(Var),
            labeling(Rest).

Resatisfiable

Yes.

See Also

indomain / 1, fd : labeling / 1, fdplex : labeling / 1