Constraint Based Problem Logic