Refactor enum Operator and logic calculator