check if obj is a number.