Skip to content

Instantly share code, notes, and snippets.

@kickroot
Last active August 29, 2015 14:12
Show Gist options
  • Select an option

  • Save kickroot/5f7751b433684727ce00 to your computer and use it in GitHub Desktop.

Select an option

Save kickroot/5f7751b433684727ce00 to your computer and use it in GitHub Desktop.
Zhi's Coding Challenge
Build a Interpreter and Compiler for Arithmetic Expressions using ANTLR3
Include operators +,-,* and / with usual mathematical precedence, brackets - “(“ and “)”
and constants that are all integers
- Build an ANTLR3 grammar for the expressions
- Generate AST
- Build an interpreter to evaluate expressions
- Add a rule to check for "division by zero"
- Build a compiler to Java bytecode (Bonus)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment