Waiting for answer This question has not been answered yet. You can hire a professional tutor to get the answer.

QUESTION

Given the following BNF descriptions for a language, in which a sentence consists of a sequence of variable declarations, you are expected to read...

Given the following BNF descriptions for a language, in which a sentence consists of a sequence of variable declarations, you are expected to read and revise/extend the grammar. (The given grammar is not complete for the designed language.)

<Var_Dcls> -> <Var_Dcl> | <Var_Dcls> <Var_Dcl>

<Var_Dcl> -> <Type> <Vars> ;

<Var> => <Var>, <Var> | <Var> *production rule I added, though not sure if I am correct?

<Type> -> int | char

<Var> -> x | y | sum | a | b | n

In the above grammar, the tokens are highlighted in bold font. 

Based on your completed grammar above, generate a sentence by derivation. (Note: You cannot provide the same sentence given in the previous question.)  

Show more
LEARN MORE EFFECTIVELY AND GET BETTER GRADES!
Ask a Question