| 
 
 
 
 
 
 
 
 
 
  
 
 
 
   | 
    | 
 
 
     
 
 
  Example 1 
   
  
 
 
 
 Here, identifiers  consist of letters and digits and begin with a 
 letter;  literals  are sequences of digits;  arithmetic operators
  are addition, subtraction, multiplication, division and assignment operators; punctuation symbols are ";" and left and right parentheses. 
 
 As input to a real lexical analyzer generator, this notation would be
 ambiguous since the left parenthesis is used in two ways. In the definition of
 an identifier, it is a metasymbol used for grouping, and in the definition of 
 punctuation,  it is an actual value.  
 
 
 
 
 
 
 
 
 
 
 
 
 
 
   
 
 
   |