Chapter 3 Lexical Analysis Outline y Role of lexical analyzer y Specification of tokens y Recognition of tokens y Lexical analyzer generator y Finite automata y Design of…