Skip to content

Power operator is_kind_of does not work on positive integers #95

@Wout4

Description

@Wout4

the power operator seems to think that an integer to the power of another (positive) integer is not a kind of integer.
This leads to an error when doing something like the following:

from docplex.cp.model import *
mdl = CpoModel()
x = integer_var_list(3, 1, 10, "X")
mdl.add(( x[0] ** x[1]) // x[2])

Because the division only accepts integer expressions

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions