added isNumber and isOperator functions