Definition of an Arithmetic Expression:
- a numeric constant
- an identifier (of a numeric type variable or constant)
- an arithmetic expression enclosed in parentheses
- two arithmetic expressions separated by a binary
arithmetic operator.
Definitions such as this are used universally to define the syntax
of programming languages, and the first step in any compiler is to use
these definitions to uncover the structure of your program: this
process is called parsing and constructs a parse tree.
For example, parsing 5 * (2 + 3)
returns: