Lex/Yacc calculator