Question: 3. Using Pattern 2, LL(1) Recursive-Descent Lexer, specify the functions necessary to build a lexer for the language specified by the grammar above. Here, you

3. Using Pattern 2, LL(1) Recursive-Descent Lexer, specify the functions necessary to build a lexer for the language specified by the grammar above. Here, you are expected to just list the name of the functions, no need to provide the code.
You are given a grammar, called SimpleExpr (see below). grammar SimpleExpr; expr : expr '+' expr | expr **? expr | ID | Number; // allow add or mult ID :('a' ... 'z' 'A'... 'Z'); // ID is Seq of > 1 letter Number : (0'... '9'); // Number is seq of> 1 digit You are given a grammar, called SimpleExpr (see below). grammar SimpleExpr; expr : expr '+' expr | expr **? expr | ID | Number; // allow add or mult ID :('a' ... 'z' 'A'... 'Z'); // ID is Seq of > 1 letter Number : (0'... '9'); // Number is seq of> 1 digit
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
