retagged by
275 views
0 votes
0 votes

Extend the lexical analyzer in Section $2.6.5$ to remove comments, defined as follows:

  1. A comment begins with $//$ and includes all characters until the end of that line.
  2. A comment begins with $/\ast$ and includes all characters through the next occurrence of the character sequence $\ast/$.  
retagged by

Please log in or register to answer this question.

Related questions

0 votes
0 votes
0 answers
1
admin asked Jul 26, 2019
210 views
Extend the lexical analyzer in Section $2.6.5$ to recognize floating point numbers such as $2. , 3.14$, and $.5$.
0 votes
0 votes
0 answers
2
admin asked Jul 26, 2019
291 views
Extend the lexical analyzer in Section $2.6.5$ to recognize the relational operators $<, <=, ==, !=, >=, >$.
0 votes
0 votes
0 answers
4
admin asked Sep 7, 2019
568 views
Add to the translation of Fig. $6.19$ rules for the following productions:$E\rightarrow E_{1}\ast E_{2}$$E\rightarrow + E_{1}\:$(unary plus)