debugging bad arithmetic expression