1 Chapter 1 SPECIFYING SYNTAX L anguage provides a means of communication by sound and written symbols. Human beings learn language as a consequence…

n old versions of Fortran that did not have the character data type,character strings were expressed in the following format:<string literal> ::= <numeral> H <string>where the <numeral> is a base-ten integer (³ 1), H is a keyword (namedafter Herman Hollerith), and <string> is a sequence of characters. Thesemantics of this string literal is correct if the numeric value of the basetennumeral matches the length of the string. Write an attribute grammarusing only synthesized attributes for the nonterminals in the definitionof <string literal>.