These are expressions in the form of:
a + b
a + e * c
You need to use Operator-Precedence Parsing
Process
- Create a table of precedences
- Operator-precendece breaks the expression into a stream of primary expressions seperated by binary operators.
- The expression is a primary expression followed by a sequence of
[binop, primaryexpr]
pairs