Try our new documentation site (beta).
Filter Content By
Version
Text Search
${sidebar_list_label} - Back
Filter by Language
and_()
and_ ( variables )
Used to set a binary decision variable equal to the logical AND of a list of other binary decision variables. You can pass the arguments as a Python list or as a comma-separated list.
Note that the Gurobi Python interface includes an equivalent
all_()
function.
Example usage:
m.addConstr(z == and_(x, y)) m.addConstr(z == and_([x, y]))
Return value:
Returns a GenExpr object.