coursework/cw03.tex
changeset 544 748207ad3ef0
parent 537 feb8a2a42625
child 556 40e22ad45744
equal deleted inserted replaced
543:16adebf18ef9 544:748207ad3ef0
    24 
    24 
    25 
    25 
    26 \subsection*{Question 1}
    26 \subsection*{Question 1}
    27 
    27 
    28 Design a grammar for the WHILE language and give the grammar
    28 Design a grammar for the WHILE language and give the grammar
    29 rules. The main categories of non-terminal should be:
    29 rules. The main categories of non-terminals should be:
    30 
    30 
    31 \begin{itemize}
    31 \begin{itemize}
    32 \item arithmetic expressions (with the operations from the
    32 \item arithmetic expressions (with the operations from the
    33   previous coursework, such as \pcode{+}, \pcode{*} and so on)
    33   previous coursework, such as \pcode{+}, \pcode{*} and so on)
    34 \item boolean expressions (such as \pcode{<}, \code{!=} and 
    34 \item boolean expressions (such as \pcode{<}, \code{!=} and