The hoc interpreter extracted from UNIX v10
This is hoc, the High Order Calculator, first described in "The UNIX Programming Environment" by Brian W. Kernighan & Rob Pike (1984). If you are not familiar with hoc, take a look at its Wikipedia page: https://en.wikipedia.org/wiki/Hoc_(programming_language) This version has been extracted from Research UNIX v10, and slightly modernized to compile with modern compilers. Build requirements: a c89 compiler, yacc (or bison), make. -- original readme below -- Changes since the book version: 1. The variable "_" contains the result of the last top-level expression evaluation, so you can re-use intermediate values without re-typing them. 2. for statement added, just like the one in C. 3. ++ and -- added. 4. Interrupts are caught; use cntrl-D to quit. 5. % operator added. 6. +=, -=, etc., added. 7. \ at end of line eats newline 8. results are 16 digits 9. tabs on output are no longer Jun 1990: 10. asin, acos, sinh, cosh, tanh, erf, erfc