Parse Tables

Property Table

Name Value
Name Simple
Author Devin Cook
Version 2.0
About This is a very simple grammar designed for use in examples
Case Sensitive False
Start Symbol Statements
Auto Whitespace True
Character Mapping Windows-1252
Character Set Unicode
Generated By GOLD Parser Builder 5.1.0
Generated Date 2012-03-26 15:54

Symbol Table

Index Name Type
0 (EOF) End of File
1 (Error) Runtime Error Symbol
2 Comment Noise
3 NewLine Noise
4 Whitespace Noise
5 '!' Lexical Group Start
6 '-' Content
7 '&' Content
8 '(' Content
9 ')' Content
10 '*' Content
11 '/' Content
12 '+' Content
13 '<' Content
14 '<=' Content
15 '<>' Content
16 '=' Content
17 '==' Content
18 '>' Content
19 '>=' Content
20 assign Content
21 display Content
22 do Content
23 else Content
24 end Content
25 Id Content
26 if Content
27 NumberLiteral Content
28 read Content
29 StringLiteral Content
30 then Content
31 while Content
32 <Add Exp> Nonterminal
33 <Expression> Nonterminal
34 <Mult Exp> Nonterminal
35 <Negate Exp> Nonterminal
36 <Statement> Nonterminal
37 <Statements> Nonterminal
38 <Value> Nonterminal

Lexical Group Table

Name Container Start End Advance Ending Nesting
Comment Line Comment ! NewLine Character Open

Production Table

Index Head ::= Handle
0 <Statements> ::= <Statement> <Statements>
1 <Statements> ::= <Statement>
2 <Statement> ::= display <Expression>
3 <Statement> ::= display <Expression> read Id
4 <Statement> ::= assign Id '=' <Expression>
5 <Statement> ::= while <Expression> do <Statements> end
6 <Statement> ::= if <Expression> then <Statements> end
7 <Statement> ::= if <Expression> then <Statements> else <Statements> end
8 <Expression> ::= <Expression> '>' <Add Exp>
9 <Expression> ::= <Expression> '<' <Add Exp>
10 <Expression> ::= <Expression> '<=' <Add Exp>
11 <Expression> ::= <Expression> '>=' <Add Exp>
12 <Expression> ::= <Expression> '==' <Add Exp>
13 <Expression> ::= <Expression> '<>' <Add Exp>
14 <Expression> ::= <Add Exp>
15 <Add Exp> ::= <Add Exp> '+' <Mult Exp>
16 <Add Exp> ::= <Add Exp> '-' <Mult Exp>
17 <Add Exp> ::= <Add Exp> '&' <Mult Exp>
18 <Add Exp> ::= <Mult Exp>
19 <Mult Exp> ::= <Mult Exp> '*' <Negate Exp>
20 <Mult Exp> ::= <Mult Exp> '/' <Negate Exp>
21 <Mult Exp> ::= <Negate Exp>
22 <Negate Exp> ::= '-' <Value>
23 <Negate Exp> ::= <Value>
24 <Value> ::= Id
25 <Value> ::= StringLiteral
26 <Value> ::= NumberLiteral
27 <Value> ::= '(' <Expression> ')'

DFA State Table

DFA State 0
Action Characters
Goto 1 &0A
Goto 2 &0D
Goto 4 &2028
Goto 5 &2029
Goto 6 &09, &0B, &0C, &20, &85, &A0, &1680, &180E, &2000 .. &200A, &2026, &202F, &205F, &3000
Goto 7 !
Goto 8 -
Goto 9 &
Goto 10 (
Goto 11 )
Goto 12 *
Goto 13 /
Goto 14 +
Goto 15 BCFGHJKLMNOPQSUVXYZbcfghjklmnopqsuvxyz
Goto 17 0123456789
Goto 20 '
Goto 23 "
Goto 26 <
Goto 29 =
Goto 31 >
Goto 33 Aa
Goto 39 Dd
Goto 47 Ee
Goto 53 Ii
Goto 55 Rr
Goto 59 Tt
Goto 63 Ww

DFA State 1
Action Characters
Accept NewLine  

DFA State 2
Action Characters
Goto 3 &0A
Accept NewLine  

DFA State 3
Action Characters
Accept NewLine  

DFA State 4
Action Characters
Accept NewLine  

DFA State 5
Action Characters
Accept NewLine  

DFA State 6
Action Characters
Goto 6 &09, &0B, &0C, &20, &85, &A0, &1680, &180E, &2000 .. &200A, &2026, &202F, &205F, &3000
Accept Whitespace  

DFA State 7
Action Characters
Accept '!'  

DFA State 8
Action Characters
Accept '-'  

DFA State 9
Action Characters
Accept '&'  

DFA State 10
Action Characters
Accept '('  

DFA State 11
Action Characters
Accept ')'  

DFA State 12
Action Characters
Accept '*'  

DFA State 13
Action Characters
Accept '/'  

DFA State 14
Action Characters
Accept '+'  

DFA State 15
Action Characters
Goto 16 0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz
Accept Id  

DFA State 16
Action Characters
Goto 16 0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz
Accept Id  

DFA State 17
Action Characters
Goto 17 0123456789
Goto 18 .
Accept NumberLiteral  

DFA State 18
Action Characters
Goto 19 0123456789

DFA State 19
Action Characters
Goto 19 0123456789
Accept NumberLiteral  

DFA State 20
Action Characters
Goto 21 {Space}!"#$%&()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~{NBSP}
Goto 22 '

DFA State 21
Action Characters
Goto 21 {Space}!"#$%&()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~{NBSP}
Goto 22 '

DFA State 22
Action Characters
Accept StringLiteral  

DFA State 23
Action Characters
Goto 24 {Space}!#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~{NBSP}
Goto 25 "

DFA State 24
Action Characters
Goto 24 {Space}!#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~{NBSP}
Goto 25 "

DFA State 25
Action Characters
Accept StringLiteral  

DFA State 26
Action Characters
Goto 27 =
Goto 28 >
Accept '<'  

DFA State 27
Action Characters
Accept '<='  

DFA State 28
Action Characters
Accept '<>'  

DFA State 29
Action Characters
Goto 30 =
Accept '='  

DFA State 30
Action Characters
Accept '=='  

DFA State 31
Action Characters
Goto 32 =
Accept '>'  

DFA State 32
Action Characters
Accept '>='  

DFA State 33
Action Characters
Goto 16 0123456789ABCDEFGHIJKLMNOPQRTUVWXYZabcdefghijklmnopqrtuvwxyz
Goto 34 Ss
Accept Id  

DFA State 34
Action Characters
Goto 16 0123456789ABCDEFGHIJKLMNOPQRTUVWXYZabcdefghijklmnopqrtuvwxyz
Goto 35 Ss
Accept Id  

DFA State 35
Action Characters
Goto 16 0123456789ABCDEFGHJKLMNOPQRSTUVWXYZabcdefghjklmnopqrstuvwxyz
Goto 36 Ii
Accept Id  

DFA State 36
Action Characters
Goto 16 0123456789ABCDEFHIJKLMNOPQRSTUVWXYZabcdefhijklmnopqrstuvwxyz
Goto 37 Gg
Accept Id  

DFA State 37
Action Characters
Goto 16 0123456789ABCDEFGHIJKLMOPQRSTUVWXYZabcdefghijklmopqrstuvwxyz
Goto 38 Nn
Accept Id  

DFA State 38
Action Characters
Goto 16 0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz
Accept assign  

DFA State 39
Action Characters
Goto 16 0123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghjklmnpqrstuvwxyz
Goto 40 Ii
Goto 46 Oo
Accept Id  

DFA State 40
Action Characters
Goto 16 0123456789ABCDEFGHIJKLMNOPQRTUVWXYZabcdefghijklmnopqrtuvwxyz
Goto 41 Ss
Accept Id  

DFA State 41
Action Characters
Goto 16 0123456789ABCDEFGHIJKLMNOQRSTUVWXYZabcdefghijklmnoqrstuvwxyz
Goto 42 Pp
Accept Id  

DFA State 42
Action Characters
Goto 16 0123456789ABCDEFGHIJKMNOPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz
Goto 43 Ll
Accept Id  

DFA State 43
Action Characters
Goto 16 0123456789BCDEFGHIJKLMNOPQRSTUVWXYZbcdefghijklmnopqrstuvwxyz
Goto 44 Aa
Accept Id  

DFA State 44
Action Characters
Goto 16 0123456789ABCDEFGHIJKLMNOPQRSTUVWXZabcdefghijklmnopqrstuvwxz
Goto 45 Yy
Accept Id  

DFA State 45
Action Characters
Goto 16 0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz
Accept display  

DFA State 46
Action Characters
Goto 16 0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz
Accept do  

DFA State 47
Action Characters
Goto 16 0123456789ABCDEFGHIJKMOPQRSTUVWXYZabcdefghijkmopqrstuvwxyz
Goto 48 Ll
Goto 51 Nn
Accept Id  

DFA State 48
Action Characters
Goto 16 0123456789ABCDEFGHIJKLMNOPQRTUVWXYZabcdefghijklmnopqrtuvwxyz
Goto 49 Ss
Accept Id  

DFA State 49
Action Characters
Goto 16 0123456789ABCDFGHIJKLMNOPQRSTUVWXYZabcdfghijklmnopqrstuvwxyz
Goto 50 Ee
Accept Id  

DFA State 50
Action Characters
Goto 16 0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz
Accept else  

DFA State 51
Action Characters
Goto 16 0123456789ABCEFGHIJKLMNOPQRSTUVWXYZabcefghijklmnopqrstuvwxyz
Goto 52 Dd
Accept Id  

DFA State 52
Action Characters
Goto 16 0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz
Accept end  

DFA State 53
Action Characters
Goto 16 0123456789ABCDEGHIJKLMNOPQRSTUVWXYZabcdeghijklmnopqrstuvwxyz
Goto 54 Ff
Accept Id  

DFA State 54
Action Characters
Goto 16 0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz
Accept if  

DFA State 55
Action Characters
Goto 16 0123456789ABCDFGHIJKLMNOPQRSTUVWXYZabcdfghijklmnopqrstuvwxyz
Goto 56 Ee
Accept Id  

DFA State 56
Action Characters
Goto 16 0123456789BCDEFGHIJKLMNOPQRSTUVWXYZbcdefghijklmnopqrstuvwxyz
Goto 57 Aa
Accept Id  

DFA State 57
Action Characters
Goto 16 0123456789ABCEFGHIJKLMNOPQRSTUVWXYZabcefghijklmnopqrstuvwxyz
Goto 58 Dd
Accept Id  

DFA State 58
Action Characters
Goto 16 0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz
Accept read  

DFA State 59
Action Characters
Goto 16 0123456789ABCDEFGIJKLMNOPQRSTUVWXYZabcdefgijklmnopqrstuvwxyz
Goto 60 Hh
Accept Id  

DFA State 60
Action Characters
Goto 16 0123456789ABCDFGHIJKLMNOPQRSTUVWXYZabcdfghijklmnopqrstuvwxyz
Goto 61 Ee
Accept Id  

DFA State 61
Action Characters
Goto 16 0123456789ABCDEFGHIJKLMOPQRSTUVWXYZabcdefghijklmopqrstuvwxyz
Goto 62 Nn
Accept Id  

DFA State 62
Action Characters
Goto 16 0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz
Accept then  

DFA State 63
Action Characters
Goto 16 0123456789ABCDEFGIJKLMNOPQRSTUVWXYZabcdefgijklmnopqrstuvwxyz
Goto 64 Hh
Accept Id  

DFA State 64
Action Characters
Goto 16 0123456789ABCDEFGHJKLMNOPQRSTUVWXYZabcdefghjklmnopqrstuvwxyz
Goto 65 Ii
Accept Id  

DFA State 65
Action Characters
Goto 16 0123456789ABCDEFGHIJKMNOPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz
Goto 66 Ll
Accept Id  

DFA State 66
Action Characters
Goto 16 0123456789ABCDFGHIJKLMNOPQRSTUVWXYZabcdfghijklmnopqrstuvwxyz
Goto 67 Ee
Accept Id  

DFA State 67
Action Characters
Goto 16 0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz
Accept while  

LALR State Table

LALR State 0
Configuration Lookahead
<S'> ::= · <Statements> (EOF)  
<Statements> ::= · <Statement> <Statements> EOF
<Statements> ::= · <Statement> EOF
<Statement> ::= · display <Expression> EOF assign display if while
<Statement> ::= · display <Expression> read Id EOF assign display if while
<Statement> ::= · assign Id '=' <Expression> EOF assign display if while
<Statement> ::= · while <Expression> do <Statements> end EOF assign display if while
<Statement> ::= · if <Expression> then <Statements> end EOF assign display if while
<Statement> ::= · if <Expression> then <Statements> else <Statements> end EOF assign display if while
Actions
assign Shift to State 1
display Shift to State 2
if Shift to State 3
while Shift to State 4
<Statement> Go to State 5
<Statements> Go to State 6

LALR State 1
Configuration Lookahead
<Statement> ::= assign · Id '=' <Expression> EOF assign display else end if while
Actions
Id Shift to State 7
Prior States
0 5 36 37 54

LALR State 2
Configuration Lookahead
<Statement> ::= display · <Expression> EOF assign display else end if while
<Statement> ::= display · <Expression> read Id EOF assign display else end if while
<Expression> ::= · <Expression> '>' <Add Exp> EOF < <= <> == > >= assign display else end if read while
<Expression> ::= · <Expression> '<' <Add Exp> EOF < <= <> == > >= assign display else end if read while
<Expression> ::= · <Expression> '<=' <Add Exp> EOF < <= <> == > >= assign display else end if read while
<Expression> ::= · <Expression> '>=' <Add Exp> EOF < <= <> == > >= assign display else end if read while
<Expression> ::= · <Expression> '==' <Add Exp> EOF < <= <> == > >= assign display else end if read while
<Expression> ::= · <Expression> '<>' <Add Exp> EOF < <= <> == > >= assign display else end if read while
<Expression> ::= · <Add Exp> EOF < <= <> == > >= assign display else end if read while
<Add Exp> ::= · <Add Exp> '+' <Mult Exp> EOF - & + < <= <> == > >= assign display else end if read while
<Add Exp> ::= · <Add Exp> '-' <Mult Exp> EOF - & + < <= <> == > >= assign display else end if read while
<Add Exp> ::= · <Add Exp> '&' <Mult Exp> EOF - & + < <= <> == > >= assign display else end if read while
<Add Exp> ::= · <Mult Exp> EOF - & + < <= <> == > >= assign display else end if read while
<Mult Exp> ::= · <Mult Exp> '*' <Negate Exp> EOF - & * / + < <= <> == > >= assign display else end if read while
<Mult Exp> ::= · <Mult Exp> '/' <Negate Exp> EOF - & * / + < <= <> == > >= assign display else end if read while
<Mult Exp> ::= · <Negate Exp> EOF - & * / + < <= <> == > >= assign display else end if read while
<Negate Exp> ::= · '-' <Value> EOF - & * / + < <= <> == > >= assign display else end if read while
<Negate Exp> ::= · <Value> EOF - & * / + < <= <> == > >= assign display else end if read while
<Value> ::= · Id EOF - & * / + < <= <> == > >= assign display else end if read while
<Value> ::= · StringLiteral EOF - & * / + < <= <> == > >= assign display else end if read while
<Value> ::= · NumberLiteral EOF - & * / + < <= <> == > >= assign display else end if read while
<Value> ::= · '(' <Expression> ')' EOF - & * / + < <= <> == > >= assign display else end if read while
Actions
'-' Shift to State 8
'(' Shift to State 9
Id Shift to State 10
NumberLiteral Shift to State 11
StringLiteral Shift to State 12
<Add Exp> Go to State 13
<Expression> Go to State 14
<Mult Exp> Go to State 15
<Negate Exp> Go to State 16
<Value> Go to State 17
Prior States
0 5 36 37 54

LALR State 3
Configuration Lookahead
<Statement> ::= if · <Expression> then <Statements> end EOF assign display else end if while
<Statement> ::= if · <Expression> then <Statements> else <Statements> end EOF assign display else end if while
<Expression> ::= · <Expression> '>' <Add Exp> < <= <> == > >= then
<Expression> ::= · <Expression> '<' <Add Exp> < <= <> == > >= then
<Expression> ::= · <Expression> '<=' <Add Exp> < <= <> == > >= then
<Expression> ::= · <Expression> '>=' <Add Exp> < <= <> == > >= then
<Expression> ::= · <Expression> '==' <Add Exp> < <= <> == > >= then
<Expression> ::= · <Expression> '<>' <Add Exp> < <= <> == > >= then
<Expression> ::= · <Add Exp> < <= <> == > >= then
<Add Exp> ::= · <Add Exp> '+' <Mult Exp> - & + < <= <> == > >= then
<Add Exp> ::= · <Add Exp> '-' <Mult Exp> - & + < <= <> == > >= then
<Add Exp> ::= · <Add Exp> '&' <Mult Exp> - & + < <= <> == > >= then
<Add Exp> ::= · <Mult Exp> - & + < <= <> == > >= then
<Mult Exp> ::= · <Mult Exp> '*' <Negate Exp> - & * / + < <= <> == > >= then
<Mult Exp> ::= · <Mult Exp> '/' <Negate Exp> - & * / + < <= <> == > >= then
<Mult Exp> ::= · <Negate Exp> - & * / + < <= <> == > >= then
<Negate Exp> ::= · '-' <Value> - & * / + < <= <> == > >= then
<Negate Exp> ::= · <Value> - & * / + < <= <> == > >= then
<Value> ::= · Id - & * / + < <= <> == > >= then
<Value> ::= · StringLiteral - & * / + < <= <> == > >= then
<Value> ::= · NumberLiteral - & * / + < <= <> == > >= then
<Value> ::= · '(' <Expression> ')' - & * / + < <= <> == > >= then
Actions
'-' Shift to State 8
'(' Shift to State 9
Id Shift to State 10
NumberLiteral Shift to State 11
StringLiteral Shift to State 12
<Add Exp> Go to State 13
<Expression> Go to State 18
<Mult Exp> Go to State 15
<Negate Exp> Go to State 16
<Value> Go to State 17
Prior States
0 5 36 37 54

LALR State 4
Configuration Lookahead
<Statement> ::= while · <Expression> do <Statements> end EOF assign display else end if while
<Expression> ::= · <Expression> '>' <Add Exp> < <= <> == > >= do
<Expression> ::= · <Expression> '<' <Add Exp> < <= <> == > >= do
<Expression> ::= · <Expression> '<=' <Add Exp> < <= <> == > >= do
<Expression> ::= · <Expression> '>=' <Add Exp> < <= <> == > >= do
<Expression> ::= · <Expression> '==' <Add Exp> < <= <> == > >= do
<Expression> ::= · <Expression> '<>' <Add Exp> < <= <> == > >= do
<Expression> ::= · <Add Exp> < <= <> == > >= do
<Add Exp> ::= · <Add Exp> '+' <Mult Exp> - & + < <= <> == > >= do
<Add Exp> ::= · <Add Exp> '-' <Mult Exp> - & + < <= <> == > >= do
<Add Exp> ::= · <Add Exp> '&' <Mult Exp> - & + < <= <> == > >= do
<Add Exp> ::= · <Mult Exp> - & + < <= <> == > >= do
<Mult Exp> ::= · <Mult Exp> '*' <Negate Exp> - & * / + < <= <> == > >= do
<Mult Exp> ::= · <Mult Exp> '/' <Negate Exp> - & * / + < <= <> == > >= do
<Mult Exp> ::= · <Negate Exp> - & * / + < <= <> == > >= do
<Negate Exp> ::= · '-' <Value> - & * / + < <= <> == > >= do
<Negate Exp> ::= · <Value> - & * / + < <= <> == > >= do
<Value> ::= · Id - & * / + < <= <> == > >= do
<Value> ::= · StringLiteral - & * / + < <= <> == > >= do
<Value> ::= · NumberLiteral - & * / + < <= <> == > >= do
<Value> ::= · '(' <Expression> ')' - & * / + < <= <> == > >= do
Actions
'-' Shift to State 8
'(' Shift to State 9
Id Shift to State 10
NumberLiteral Shift to State 11
StringLiteral Shift to State 12
<Add Exp> Go to State 13
<Expression> Go to State 19
<Mult Exp> Go to State 15
<Negate Exp> Go to State 16
<Value> Go to State 17
Prior States
0 5 36 37 54

LALR State 5
Configuration Lookahead
<Statements> ::= <Statement> · <Statements> EOF else end
<Statements> ::= <Statement> · EOF else end
<Statements> ::= · <Statement> <Statements> EOF else end
<Statements> ::= · <Statement> EOF else end
<Statement> ::= · display <Expression> EOF assign display else end if while
<Statement> ::= · display <Expression> read Id EOF assign display else end if while
<Statement> ::= · assign Id '=' <Expression> EOF assign display else end if while
<Statement> ::= · while <Expression> do <Statements> end EOF assign display else end if while
<Statement> ::= · if <Expression> then <Statements> end EOF assign display else end if while
<Statement> ::= · if <Expression> then <Statements> else <Statements> end EOF assign display else end if while
Actions
assign Shift to State 1
display Shift to State 2
if Shift to State 3
while Shift to State 4
<Statement> Go to State 5
<Statements> Go to State 20
(EOF) Reduce Production 1
else Reduce Production 1
end Reduce Production 1
Prior States
0 5 36 37 54

LALR State 6
Configuration Lookahead
<S'> ::= <Statements> · (EOF)  
Actions
(EOF) Accept
Prior States
0

LALR State 7
Configuration Lookahead
<Statement> ::= assign Id · '=' <Expression> EOF assign display else end if while
Actions
'=' Shift to State 21
Prior States
1

LALR State 8
Configuration Lookahead
<Negate Exp> ::= '-' · <Value> EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Value> ::= · Id EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Value> ::= · StringLiteral EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Value> ::= · NumberLiteral EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Value> ::= · '(' <Expression> ')' EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
Actions
'(' Shift to State 9
Id Shift to State 10
NumberLiteral Shift to State 11
StringLiteral Shift to State 12
<Value> Go to State 22
Prior States
2 3 4 9 21 24 25 26 27 28 29 30 31 32 34 35

LALR State 9
Configuration Lookahead
<Value> ::= '(' · <Expression> ')' EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Expression> ::= · <Expression> '>' <Add Exp> ) < <= <> == > >=
<Expression> ::= · <Expression> '<' <Add Exp> ) < <= <> == > >=
<Expression> ::= · <Expression> '<=' <Add Exp> ) < <= <> == > >=
<Expression> ::= · <Expression> '>=' <Add Exp> ) < <= <> == > >=
<Expression> ::= · <Expression> '==' <Add Exp> ) < <= <> == > >=
<Expression> ::= · <Expression> '<>' <Add Exp> ) < <= <> == > >=
<Expression> ::= · <Add Exp> ) < <= <> == > >=
<Add Exp> ::= · <Add Exp> '+' <Mult Exp> - & ) + < <= <> == > >=
<Add Exp> ::= · <Add Exp> '-' <Mult Exp> - & ) + < <= <> == > >=
<Add Exp> ::= · <Add Exp> '&' <Mult Exp> - & ) + < <= <> == > >=
<Add Exp> ::= · <Mult Exp> - & ) + < <= <> == > >=
<Mult Exp> ::= · <Mult Exp> '*' <Negate Exp> - & ) * / + < <= <> == > >=
<Mult Exp> ::= · <Mult Exp> '/' <Negate Exp> - & ) * / + < <= <> == > >=
<Mult Exp> ::= · <Negate Exp> - & ) * / + < <= <> == > >=
<Negate Exp> ::= · '-' <Value> - & ) * / + < <= <> == > >=
<Negate Exp> ::= · <Value> - & ) * / + < <= <> == > >=
<Value> ::= · Id - & ) * / + < <= <> == > >=
<Value> ::= · StringLiteral - & ) * / + < <= <> == > >=
<Value> ::= · NumberLiteral - & ) * / + < <= <> == > >=
<Value> ::= · '(' <Expression> ')' - & ) * / + < <= <> == > >=
Actions
'-' Shift to State 8
'(' Shift to State 9
Id Shift to State 10
NumberLiteral Shift to State 11
StringLiteral Shift to State 12
<Add Exp> Go to State 13
<Expression> Go to State 23
<Mult Exp> Go to State 15
<Negate Exp> Go to State 16
<Value> Go to State 17
Prior States
2 3 4 8 9 21 24 25 26 27 28 29 30 31 32 34 35

LALR State 10
Configuration Lookahead
<Value> ::= Id · EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
Actions
(EOF) Reduce Production 24
'-' Reduce Production 24
'&' Reduce Production 24
')' Reduce Production 24
'*' Reduce Production 24
'/' Reduce Production 24
'+' Reduce Production 24
'<' Reduce Production 24
'<=' Reduce Production 24
'<>' Reduce Production 24
'==' Reduce Production 24
'>' Reduce Production 24
'>=' Reduce Production 24
assign Reduce Production 24
display Reduce Production 24
do Reduce Production 24
else Reduce Production 24
end Reduce Production 24
if Reduce Production 24
read Reduce Production 24
then Reduce Production 24
while Reduce Production 24
Prior States
2 3 4 8 9 21 24 25 26 27 28 29 30 31 32 34 35

LALR State 11
Configuration Lookahead
<Value> ::= NumberLiteral · EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
Actions
(EOF) Reduce Production 26
'-' Reduce Production 26
'&' Reduce Production 26
')' Reduce Production 26
'*' Reduce Production 26
'/' Reduce Production 26
'+' Reduce Production 26
'<' Reduce Production 26
'<=' Reduce Production 26
'<>' Reduce Production 26
'==' Reduce Production 26
'>' Reduce Production 26
'>=' Reduce Production 26
assign Reduce Production 26
display Reduce Production 26
do Reduce Production 26
else Reduce Production 26
end Reduce Production 26
if Reduce Production 26
read Reduce Production 26
then Reduce Production 26
while Reduce Production 26
Prior States
2 3 4 8 9 21 24 25 26 27 28 29 30 31 32 34 35

LALR State 12
Configuration Lookahead
<Value> ::= StringLiteral · EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
Actions
(EOF) Reduce Production 25
'-' Reduce Production 25
'&' Reduce Production 25
')' Reduce Production 25
'*' Reduce Production 25
'/' Reduce Production 25
'+' Reduce Production 25
'<' Reduce Production 25
'<=' Reduce Production 25
'<>' Reduce Production 25
'==' Reduce Production 25
'>' Reduce Production 25
'>=' Reduce Production 25
assign Reduce Production 25
display Reduce Production 25
do Reduce Production 25
else Reduce Production 25
end Reduce Production 25
if Reduce Production 25
read Reduce Production 25
then Reduce Production 25
while Reduce Production 25
Prior States
2 3 4 8 9 21 24 25 26 27 28 29 30 31 32 34 35

LALR State 13
Configuration Lookahead
<Expression> ::= <Add Exp> · EOF ) < <= <> == > >= assign display do else end if read then while
<Add Exp> ::= <Add Exp> · '+' <Mult Exp> EOF - & ) + < <= <> == > >= assign display do else end if read then while
<Add Exp> ::= <Add Exp> · '-' <Mult Exp> EOF - & ) + < <= <> == > >= assign display do else end if read then while
<Add Exp> ::= <Add Exp> · '&' <Mult Exp> EOF - & ) + < <= <> == > >= assign display do else end if read then while
Actions
'-' Shift to State 24
'&' Shift to State 25
'+' Shift to State 26
(EOF) Reduce Production 14
')' Reduce Production 14
'<' Reduce Production 14
'<=' Reduce Production 14
'<>' Reduce Production 14
'==' Reduce Production 14
'>' Reduce Production 14
'>=' Reduce Production 14
assign Reduce Production 14
display Reduce Production 14
do Reduce Production 14
else Reduce Production 14
end Reduce Production 14
if Reduce Production 14
read Reduce Production 14
then Reduce Production 14
while Reduce Production 14
Prior States
2 3 4 9 21

LALR State 14
Configuration Lookahead
<Statement> ::= display <Expression> · EOF assign display else end if while
<Statement> ::= display <Expression> · read Id EOF assign display else end if while
<Expression> ::= <Expression> · '>' <Add Exp> EOF < <= <> == > >= assign display else end if read while
<Expression> ::= <Expression> · '<' <Add Exp> EOF < <= <> == > >= assign display else end if read while
<Expression> ::= <Expression> · '<=' <Add Exp> EOF < <= <> == > >= assign display else end if read while
<Expression> ::= <Expression> · '>=' <Add Exp> EOF < <= <> == > >= assign display else end if read while
<Expression> ::= <Expression> · '==' <Add Exp> EOF < <= <> == > >= assign display else end if read while
<Expression> ::= <Expression> · '<>' <Add Exp> EOF < <= <> == > >= assign display else end if read while
Actions
'<' Shift to State 27
'<=' Shift to State 28
'<>' Shift to State 29
'==' Shift to State 30
'>' Shift to State 31
'>=' Shift to State 32
read Shift to State 33
(EOF) Reduce Production 2
assign Reduce Production 2
display Reduce Production 2
else Reduce Production 2
end Reduce Production 2
if Reduce Production 2
while Reduce Production 2
Prior States
2

LALR State 15
Configuration Lookahead
<Add Exp> ::= <Mult Exp> · EOF - & ) + < <= <> == > >= assign display do else end if read then while
<Mult Exp> ::= <Mult Exp> · '*' <Negate Exp> EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Mult Exp> ::= <Mult Exp> · '/' <Negate Exp> EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
Actions
'*' Shift to State 34
'/' Shift to State 35
(EOF) Reduce Production 18
'-' Reduce Production 18
'&' Reduce Production 18
')' Reduce Production 18
'+' Reduce Production 18
'<' Reduce Production 18
'<=' Reduce Production 18
'<>' Reduce Production 18
'==' Reduce Production 18
'>' Reduce Production 18
'>=' Reduce Production 18
assign Reduce Production 18
display Reduce Production 18
do Reduce Production 18
else Reduce Production 18
end Reduce Production 18
if Reduce Production 18
read Reduce Production 18
then Reduce Production 18
while Reduce Production 18
Prior States
2 3 4 9 21 27 28 29 30 31 32

LALR State 16
Configuration Lookahead
<Mult Exp> ::= <Negate Exp> · EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
Actions
(EOF) Reduce Production 21
'-' Reduce Production 21
'&' Reduce Production 21
')' Reduce Production 21
'*' Reduce Production 21
'/' Reduce Production 21
'+' Reduce Production 21
'<' Reduce Production 21
'<=' Reduce Production 21
'<>' Reduce Production 21
'==' Reduce Production 21
'>' Reduce Production 21
'>=' Reduce Production 21
assign Reduce Production 21
display Reduce Production 21
do Reduce Production 21
else Reduce Production 21
end Reduce Production 21
if Reduce Production 21
read Reduce Production 21
then Reduce Production 21
while Reduce Production 21
Prior States
2 3 4 9 21 24 25 26 27 28 29 30 31 32

LALR State 17
Configuration Lookahead
<Negate Exp> ::= <Value> · EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
Actions
(EOF) Reduce Production 23
'-' Reduce Production 23
'&' Reduce Production 23
')' Reduce Production 23
'*' Reduce Production 23
'/' Reduce Production 23
'+' Reduce Production 23
'<' Reduce Production 23
'<=' Reduce Production 23
'<>' Reduce Production 23
'==' Reduce Production 23
'>' Reduce Production 23
'>=' Reduce Production 23
assign Reduce Production 23
display Reduce Production 23
do Reduce Production 23
else Reduce Production 23
end Reduce Production 23
if Reduce Production 23
read Reduce Production 23
then Reduce Production 23
while Reduce Production 23
Prior States
2 3 4 9 21 24 25 26 27 28 29 30 31 32 34 35

LALR State 18
Configuration Lookahead
<Statement> ::= if <Expression> · then <Statements> end EOF assign display else end if while
<Statement> ::= if <Expression> · then <Statements> else <Statements> end EOF assign display else end if while
<Expression> ::= <Expression> · '>' <Add Exp> < <= <> == > >= then
<Expression> ::= <Expression> · '<' <Add Exp> < <= <> == > >= then
<Expression> ::= <Expression> · '<=' <Add Exp> < <= <> == > >= then
<Expression> ::= <Expression> · '>=' <Add Exp> < <= <> == > >= then
<Expression> ::= <Expression> · '==' <Add Exp> < <= <> == > >= then
<Expression> ::= <Expression> · '<>' <Add Exp> < <= <> == > >= then
Actions
'<' Shift to State 27
'<=' Shift to State 28
'<>' Shift to State 29
'==' Shift to State 30
'>' Shift to State 31
'>=' Shift to State 32
then Shift to State 36
Prior States
3

LALR State 19
Configuration Lookahead
<Statement> ::= while <Expression> · do <Statements> end EOF assign display else end if while
<Expression> ::= <Expression> · '>' <Add Exp> < <= <> == > >= do
<Expression> ::= <Expression> · '<' <Add Exp> < <= <> == > >= do
<Expression> ::= <Expression> · '<=' <Add Exp> < <= <> == > >= do
<Expression> ::= <Expression> · '>=' <Add Exp> < <= <> == > >= do
<Expression> ::= <Expression> · '==' <Add Exp> < <= <> == > >= do
<Expression> ::= <Expression> · '<>' <Add Exp> < <= <> == > >= do
Actions
'<' Shift to State 27
'<=' Shift to State 28
'<>' Shift to State 29
'==' Shift to State 30
'>' Shift to State 31
'>=' Shift to State 32
do Shift to State 37
Prior States
4

LALR State 20
Configuration Lookahead
<Statements> ::= <Statement> <Statements> · EOF else end
Actions
(EOF) Reduce Production 0
else Reduce Production 0
end Reduce Production 0
Prior States
5

LALR State 21
Configuration Lookahead
<Statement> ::= assign Id '=' · <Expression> EOF assign display else end if while
<Expression> ::= · <Expression> '>' <Add Exp> EOF < <= <> == > >= assign display else end if while
<Expression> ::= · <Expression> '<' <Add Exp> EOF < <= <> == > >= assign display else end if while
<Expression> ::= · <Expression> '<=' <Add Exp> EOF < <= <> == > >= assign display else end if while
<Expression> ::= · <Expression> '>=' <Add Exp> EOF < <= <> == > >= assign display else end if while
<Expression> ::= · <Expression> '==' <Add Exp> EOF < <= <> == > >= assign display else end if while
<Expression> ::= · <Expression> '<>' <Add Exp> EOF < <= <> == > >= assign display else end if while
<Expression> ::= · <Add Exp> EOF < <= <> == > >= assign display else end if while
<Add Exp> ::= · <Add Exp> '+' <Mult Exp> EOF - & + < <= <> == > >= assign display else end if while
<Add Exp> ::= · <Add Exp> '-' <Mult Exp> EOF - & + < <= <> == > >= assign display else end if while
<Add Exp> ::= · <Add Exp> '&' <Mult Exp> EOF - & + < <= <> == > >= assign display else end if while
<Add Exp> ::= · <Mult Exp> EOF - & + < <= <> == > >= assign display else end if while
<Mult Exp> ::= · <Mult Exp> '*' <Negate Exp> EOF - & * / + < <= <> == > >= assign display else end if while
<Mult Exp> ::= · <Mult Exp> '/' <Negate Exp> EOF - & * / + < <= <> == > >= assign display else end if while
<Mult Exp> ::= · <Negate Exp> EOF - & * / + < <= <> == > >= assign display else end if while
<Negate Exp> ::= · '-' <Value> EOF - & * / + < <= <> == > >= assign display else end if while
<Negate Exp> ::= · <Value> EOF - & * / + < <= <> == > >= assign display else end if while
<Value> ::= · Id EOF - & * / + < <= <> == > >= assign display else end if while
<Value> ::= · StringLiteral EOF - & * / + < <= <> == > >= assign display else end if while
<Value> ::= · NumberLiteral EOF - & * / + < <= <> == > >= assign display else end if while
<Value> ::= · '(' <Expression> ')' EOF - & * / + < <= <> == > >= assign display else end if while
Actions
'-' Shift to State 8
'(' Shift to State 9
Id Shift to State 10
NumberLiteral Shift to State 11
StringLiteral Shift to State 12
<Add Exp> Go to State 13
<Expression> Go to State 38
<Mult Exp> Go to State 15
<Negate Exp> Go to State 16
<Value> Go to State 17
Prior States
7

LALR State 22
Configuration Lookahead
<Negate Exp> ::= '-' <Value> · EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
Actions
(EOF) Reduce Production 22
'-' Reduce Production 22
'&' Reduce Production 22
')' Reduce Production 22
'*' Reduce Production 22
'/' Reduce Production 22
'+' Reduce Production 22
'<' Reduce Production 22
'<=' Reduce Production 22
'<>' Reduce Production 22
'==' Reduce Production 22
'>' Reduce Production 22
'>=' Reduce Production 22
assign Reduce Production 22
display Reduce Production 22
do Reduce Production 22
else Reduce Production 22
end Reduce Production 22
if Reduce Production 22
read Reduce Production 22
then Reduce Production 22
while Reduce Production 22
Prior States
8

LALR State 23
Configuration Lookahead
<Value> ::= '(' <Expression> · ')' EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Expression> ::= <Expression> · '>' <Add Exp> ) < <= <> == > >=
<Expression> ::= <Expression> · '<' <Add Exp> ) < <= <> == > >=
<Expression> ::= <Expression> · '<=' <Add Exp> ) < <= <> == > >=
<Expression> ::= <Expression> · '>=' <Add Exp> ) < <= <> == > >=
<Expression> ::= <Expression> · '==' <Add Exp> ) < <= <> == > >=
<Expression> ::= <Expression> · '<>' <Add Exp> ) < <= <> == > >=
Actions
')' Shift to State 39
'<' Shift to State 27
'<=' Shift to State 28
'<>' Shift to State 29
'==' Shift to State 30
'>' Shift to State 31
'>=' Shift to State 32
Prior States
9

LALR State 24
Configuration Lookahead
<Add Exp> ::= <Add Exp> '-' · <Mult Exp> EOF - & ) + < <= <> == > >= assign display do else end if read then while
<Mult Exp> ::= · <Mult Exp> '*' <Negate Exp> EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Mult Exp> ::= · <Mult Exp> '/' <Negate Exp> EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Mult Exp> ::= · <Negate Exp> EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Negate Exp> ::= · '-' <Value> EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Negate Exp> ::= · <Value> EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Value> ::= · Id EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Value> ::= · StringLiteral EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Value> ::= · NumberLiteral EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Value> ::= · '(' <Expression> ')' EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
Actions
'-' Shift to State 8
'(' Shift to State 9
Id Shift to State 10
NumberLiteral Shift to State 11
StringLiteral Shift to State 12
<Mult Exp> Go to State 40
<Negate Exp> Go to State 16
<Value> Go to State 17
Prior States
13 43 44 45 46 47 48

LALR State 25
Configuration Lookahead
<Add Exp> ::= <Add Exp> '&' · <Mult Exp> EOF - & ) + < <= <> == > >= assign display do else end if read then while
<Mult Exp> ::= · <Mult Exp> '*' <Negate Exp> EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Mult Exp> ::= · <Mult Exp> '/' <Negate Exp> EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Mult Exp> ::= · <Negate Exp> EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Negate Exp> ::= · '-' <Value> EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Negate Exp> ::= · <Value> EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Value> ::= · Id EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Value> ::= · StringLiteral EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Value> ::= · NumberLiteral EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Value> ::= · '(' <Expression> ')' EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
Actions
'-' Shift to State 8
'(' Shift to State 9
Id Shift to State 10
NumberLiteral Shift to State 11
StringLiteral Shift to State 12
<Mult Exp> Go to State 41
<Negate Exp> Go to State 16
<Value> Go to State 17
Prior States
13 43 44 45 46 47 48

LALR State 26
Configuration Lookahead
<Add Exp> ::= <Add Exp> '+' · <Mult Exp> EOF - & ) + < <= <> == > >= assign display do else end if read then while
<Mult Exp> ::= · <Mult Exp> '*' <Negate Exp> EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Mult Exp> ::= · <Mult Exp> '/' <Negate Exp> EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Mult Exp> ::= · <Negate Exp> EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Negate Exp> ::= · '-' <Value> EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Negate Exp> ::= · <Value> EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Value> ::= · Id EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Value> ::= · StringLiteral EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Value> ::= · NumberLiteral EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Value> ::= · '(' <Expression> ')' EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
Actions
'-' Shift to State 8
'(' Shift to State 9
Id Shift to State 10
NumberLiteral Shift to State 11
StringLiteral Shift to State 12
<Mult Exp> Go to State 42
<Negate Exp> Go to State 16
<Value> Go to State 17
Prior States
13 43 44 45 46 47 48

LALR State 27
Configuration Lookahead
<Expression> ::= <Expression> '<' · <Add Exp> EOF ) < <= <> == > >= assign display do else end if read then while
<Add Exp> ::= · <Add Exp> '+' <Mult Exp> EOF - & ) + < <= <> == > >= assign display do else end if read then while
<Add Exp> ::= · <Add Exp> '-' <Mult Exp> EOF - & ) + < <= <> == > >= assign display do else end if read then while
<Add Exp> ::= · <Add Exp> '&' <Mult Exp> EOF - & ) + < <= <> == > >= assign display do else end if read then while
<Add Exp> ::= · <Mult Exp> EOF - & ) + < <= <> == > >= assign display do else end if read then while
<Mult Exp> ::= · <Mult Exp> '*' <Negate Exp> EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Mult Exp> ::= · <Mult Exp> '/' <Negate Exp> EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Mult Exp> ::= · <Negate Exp> EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Negate Exp> ::= · '-' <Value> EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Negate Exp> ::= · <Value> EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Value> ::= · Id EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Value> ::= · StringLiteral EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Value> ::= · NumberLiteral EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Value> ::= · '(' <Expression> ')' EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
Actions
'-' Shift to State 8
'(' Shift to State 9
Id Shift to State 10
NumberLiteral Shift to State 11
StringLiteral Shift to State 12
<Add Exp> Go to State 43
<Mult Exp> Go to State 15
<Negate Exp> Go to State 16
<Value> Go to State 17
Prior States
14 18 19 23 38

LALR State 28
Configuration Lookahead
<Expression> ::= <Expression> '<=' · <Add Exp> EOF ) < <= <> == > >= assign display do else end if read then while
<Add Exp> ::= · <Add Exp> '+' <Mult Exp> EOF - & ) + < <= <> == > >= assign display do else end if read then while
<Add Exp> ::= · <Add Exp> '-' <Mult Exp> EOF - & ) + < <= <> == > >= assign display do else end if read then while
<Add Exp> ::= · <Add Exp> '&' <Mult Exp> EOF - & ) + < <= <> == > >= assign display do else end if read then while
<Add Exp> ::= · <Mult Exp> EOF - & ) + < <= <> == > >= assign display do else end if read then while
<Mult Exp> ::= · <Mult Exp> '*' <Negate Exp> EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Mult Exp> ::= · <Mult Exp> '/' <Negate Exp> EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Mult Exp> ::= · <Negate Exp> EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Negate Exp> ::= · '-' <Value> EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Negate Exp> ::= · <Value> EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Value> ::= · Id EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Value> ::= · StringLiteral EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Value> ::= · NumberLiteral EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Value> ::= · '(' <Expression> ')' EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
Actions
'-' Shift to State 8
'(' Shift to State 9
Id Shift to State 10
NumberLiteral Shift to State 11
StringLiteral Shift to State 12
<Add Exp> Go to State 44
<Mult Exp> Go to State 15
<Negate Exp> Go to State 16
<Value> Go to State 17
Prior States
14 18 19 23 38

LALR State 29
Configuration Lookahead
<Expression> ::= <Expression> '<>' · <Add Exp> EOF ) < <= <> == > >= assign display do else end if read then while
<Add Exp> ::= · <Add Exp> '+' <Mult Exp> EOF - & ) + < <= <> == > >= assign display do else end if read then while
<Add Exp> ::= · <Add Exp> '-' <Mult Exp> EOF - & ) + < <= <> == > >= assign display do else end if read then while
<Add Exp> ::= · <Add Exp> '&' <Mult Exp> EOF - & ) + < <= <> == > >= assign display do else end if read then while
<Add Exp> ::= · <Mult Exp> EOF - & ) + < <= <> == > >= assign display do else end if read then while
<Mult Exp> ::= · <Mult Exp> '*' <Negate Exp> EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Mult Exp> ::= · <Mult Exp> '/' <Negate Exp> EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Mult Exp> ::= · <Negate Exp> EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Negate Exp> ::= · '-' <Value> EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Negate Exp> ::= · <Value> EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Value> ::= · Id EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Value> ::= · StringLiteral EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Value> ::= · NumberLiteral EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Value> ::= · '(' <Expression> ')' EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
Actions
'-' Shift to State 8
'(' Shift to State 9
Id Shift to State 10
NumberLiteral Shift to State 11
StringLiteral Shift to State 12
<Add Exp> Go to State 45
<Mult Exp> Go to State 15
<Negate Exp> Go to State 16
<Value> Go to State 17
Prior States
14 18 19 23 38

LALR State 30
Configuration Lookahead
<Expression> ::= <Expression> '==' · <Add Exp> EOF ) < <= <> == > >= assign display do else end if read then while
<Add Exp> ::= · <Add Exp> '+' <Mult Exp> EOF - & ) + < <= <> == > >= assign display do else end if read then while
<Add Exp> ::= · <Add Exp> '-' <Mult Exp> EOF - & ) + < <= <> == > >= assign display do else end if read then while
<Add Exp> ::= · <Add Exp> '&' <Mult Exp> EOF - & ) + < <= <> == > >= assign display do else end if read then while
<Add Exp> ::= · <Mult Exp> EOF - & ) + < <= <> == > >= assign display do else end if read then while
<Mult Exp> ::= · <Mult Exp> '*' <Negate Exp> EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Mult Exp> ::= · <Mult Exp> '/' <Negate Exp> EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Mult Exp> ::= · <Negate Exp> EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Negate Exp> ::= · '-' <Value> EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Negate Exp> ::= · <Value> EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Value> ::= · Id EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Value> ::= · StringLiteral EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Value> ::= · NumberLiteral EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Value> ::= · '(' <Expression> ')' EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
Actions
'-' Shift to State 8
'(' Shift to State 9
Id Shift to State 10
NumberLiteral Shift to State 11
StringLiteral Shift to State 12
<Add Exp> Go to State 46
<Mult Exp> Go to State 15
<Negate Exp> Go to State 16
<Value> Go to State 17
Prior States
14 18 19 23 38

LALR State 31
Configuration Lookahead
<Expression> ::= <Expression> '>' · <Add Exp> EOF ) < <= <> == > >= assign display do else end if read then while
<Add Exp> ::= · <Add Exp> '+' <Mult Exp> EOF - & ) + < <= <> == > >= assign display do else end if read then while
<Add Exp> ::= · <Add Exp> '-' <Mult Exp> EOF - & ) + < <= <> == > >= assign display do else end if read then while
<Add Exp> ::= · <Add Exp> '&' <Mult Exp> EOF - & ) + < <= <> == > >= assign display do else end if read then while
<Add Exp> ::= · <Mult Exp> EOF - & ) + < <= <> == > >= assign display do else end if read then while
<Mult Exp> ::= · <Mult Exp> '*' <Negate Exp> EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Mult Exp> ::= · <Mult Exp> '/' <Negate Exp> EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Mult Exp> ::= · <Negate Exp> EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Negate Exp> ::= · '-' <Value> EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Negate Exp> ::= · <Value> EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Value> ::= · Id EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Value> ::= · StringLiteral EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Value> ::= · NumberLiteral EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Value> ::= · '(' <Expression> ')' EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
Actions
'-' Shift to State 8
'(' Shift to State 9
Id Shift to State 10
NumberLiteral Shift to State 11
StringLiteral Shift to State 12
<Add Exp> Go to State 47
<Mult Exp> Go to State 15
<Negate Exp> Go to State 16
<Value> Go to State 17
Prior States
14 18 19 23 38

LALR State 32
Configuration Lookahead
<Expression> ::= <Expression> '>=' · <Add Exp> EOF ) < <= <> == > >= assign display do else end if read then while
<Add Exp> ::= · <Add Exp> '+' <Mult Exp> EOF - & ) + < <= <> == > >= assign display do else end if read then while
<Add Exp> ::= · <Add Exp> '-' <Mult Exp> EOF - & ) + < <= <> == > >= assign display do else end if read then while
<Add Exp> ::= · <Add Exp> '&' <Mult Exp> EOF - & ) + < <= <> == > >= assign display do else end if read then while
<Add Exp> ::= · <Mult Exp> EOF - & ) + < <= <> == > >= assign display do else end if read then while
<Mult Exp> ::= · <Mult Exp> '*' <Negate Exp> EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Mult Exp> ::= · <Mult Exp> '/' <Negate Exp> EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Mult Exp> ::= · <Negate Exp> EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Negate Exp> ::= · '-' <Value> EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Negate Exp> ::= · <Value> EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Value> ::= · Id EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Value> ::= · StringLiteral EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Value> ::= · NumberLiteral EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Value> ::= · '(' <Expression> ')' EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
Actions
'-' Shift to State 8
'(' Shift to State 9
Id Shift to State 10
NumberLiteral Shift to State 11
StringLiteral Shift to State 12
<Add Exp> Go to State 48
<Mult Exp> Go to State 15
<Negate Exp> Go to State 16
<Value> Go to State 17
Prior States
14 18 19 23 38

LALR State 33
Configuration Lookahead
<Statement> ::= display <Expression> read · Id EOF assign display else end if while
Actions
Id Shift to State 49
Prior States
14

LALR State 34
Configuration Lookahead
<Mult Exp> ::= <Mult Exp> '*' · <Negate Exp> EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Negate Exp> ::= · '-' <Value> EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Negate Exp> ::= · <Value> EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Value> ::= · Id EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Value> ::= · StringLiteral EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Value> ::= · NumberLiteral EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Value> ::= · '(' <Expression> ')' EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
Actions
'-' Shift to State 8
'(' Shift to State 9
Id Shift to State 10
NumberLiteral Shift to State 11
StringLiteral Shift to State 12
<Negate Exp> Go to State 50
<Value> Go to State 17
Prior States
15 40 41 42

LALR State 35
Configuration Lookahead
<Mult Exp> ::= <Mult Exp> '/' · <Negate Exp> EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Negate Exp> ::= · '-' <Value> EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Negate Exp> ::= · <Value> EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Value> ::= · Id EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Value> ::= · StringLiteral EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Value> ::= · NumberLiteral EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Value> ::= · '(' <Expression> ')' EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
Actions
'-' Shift to State 8
'(' Shift to State 9
Id Shift to State 10
NumberLiteral Shift to State 11
StringLiteral Shift to State 12
<Negate Exp> Go to State 51
<Value> Go to State 17
Prior States
15 40 41 42

LALR State 36
Configuration Lookahead
<Statement> ::= if <Expression> then · <Statements> end EOF assign display else end if while
<Statement> ::= if <Expression> then · <Statements> else <Statements> end EOF assign display else end if while
<Statements> ::= · <Statement> <Statements> else end
<Statements> ::= · <Statement> else end
<Statement> ::= · display <Expression> assign display else end if while
<Statement> ::= · display <Expression> read Id assign display else end if while
<Statement> ::= · assign Id '=' <Expression> assign display else end if while
<Statement> ::= · while <Expression> do <Statements> end assign display else end if while
<Statement> ::= · if <Expression> then <Statements> end assign display else end if while
<Statement> ::= · if <Expression> then <Statements> else <Statements> end assign display else end if while
Actions
assign Shift to State 1
display Shift to State 2
if Shift to State 3
while Shift to State 4
<Statement> Go to State 5
<Statements> Go to State 52
Prior States
18

LALR State 37
Configuration Lookahead
<Statement> ::= while <Expression> do · <Statements> end EOF assign display else end if while
<Statements> ::= · <Statement> <Statements> end
<Statements> ::= · <Statement> end
<Statement> ::= · display <Expression> assign display end if while
<Statement> ::= · display <Expression> read Id assign display end if while
<Statement> ::= · assign Id '=' <Expression> assign display end if while
<Statement> ::= · while <Expression> do <Statements> end assign display end if while
<Statement> ::= · if <Expression> then <Statements> end assign display end if while
<Statement> ::= · if <Expression> then <Statements> else <Statements> end assign display end if while
Actions
assign Shift to State 1
display Shift to State 2
if Shift to State 3
while Shift to State 4
<Statement> Go to State 5
<Statements> Go to State 53
Prior States
19

LALR State 38
Configuration Lookahead
<Statement> ::= assign Id '=' <Expression> · EOF assign display else end if while
<Expression> ::= <Expression> · '>' <Add Exp> EOF < <= <> == > >= assign display else end if while
<Expression> ::= <Expression> · '<' <Add Exp> EOF < <= <> == > >= assign display else end if while
<Expression> ::= <Expression> · '<=' <Add Exp> EOF < <= <> == > >= assign display else end if while
<Expression> ::= <Expression> · '>=' <Add Exp> EOF < <= <> == > >= assign display else end if while
<Expression> ::= <Expression> · '==' <Add Exp> EOF < <= <> == > >= assign display else end if while
<Expression> ::= <Expression> · '<>' <Add Exp> EOF < <= <> == > >= assign display else end if while
Actions
'<' Shift to State 27
'<=' Shift to State 28
'<>' Shift to State 29
'==' Shift to State 30
'>' Shift to State 31
'>=' Shift to State 32
(EOF) Reduce Production 4
assign Reduce Production 4
display Reduce Production 4
else Reduce Production 4
end Reduce Production 4
if Reduce Production 4
while Reduce Production 4
Prior States
21

LALR State 39
Configuration Lookahead
<Value> ::= '(' <Expression> ')' · EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
Actions
(EOF) Reduce Production 27
'-' Reduce Production 27
'&' Reduce Production 27
')' Reduce Production 27
'*' Reduce Production 27
'/' Reduce Production 27
'+' Reduce Production 27
'<' Reduce Production 27
'<=' Reduce Production 27
'<>' Reduce Production 27
'==' Reduce Production 27
'>' Reduce Production 27
'>=' Reduce Production 27
assign Reduce Production 27
display Reduce Production 27
do Reduce Production 27
else Reduce Production 27
end Reduce Production 27
if Reduce Production 27
read Reduce Production 27
then Reduce Production 27
while Reduce Production 27
Prior States
23

LALR State 40
Configuration Lookahead
<Add Exp> ::= <Add Exp> '-' <Mult Exp> · EOF - & ) + < <= <> == > >= assign display do else end if read then while
<Mult Exp> ::= <Mult Exp> · '*' <Negate Exp> EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Mult Exp> ::= <Mult Exp> · '/' <Negate Exp> EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
Actions
'*' Shift to State 34
'/' Shift to State 35
(EOF) Reduce Production 16
'-' Reduce Production 16
'&' Reduce Production 16
')' Reduce Production 16
'+' Reduce Production 16
'<' Reduce Production 16
'<=' Reduce Production 16
'<>' Reduce Production 16
'==' Reduce Production 16
'>' Reduce Production 16
'>=' Reduce Production 16
assign Reduce Production 16
display Reduce Production 16
do Reduce Production 16
else Reduce Production 16
end Reduce Production 16
if Reduce Production 16
read Reduce Production 16
then Reduce Production 16
while Reduce Production 16
Prior States
24

LALR State 41
Configuration Lookahead
<Add Exp> ::= <Add Exp> '&' <Mult Exp> · EOF - & ) + < <= <> == > >= assign display do else end if read then while
<Mult Exp> ::= <Mult Exp> · '*' <Negate Exp> EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Mult Exp> ::= <Mult Exp> · '/' <Negate Exp> EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
Actions
'*' Shift to State 34
'/' Shift to State 35
(EOF) Reduce Production 17
'-' Reduce Production 17
'&' Reduce Production 17
')' Reduce Production 17
'+' Reduce Production 17
'<' Reduce Production 17
'<=' Reduce Production 17
'<>' Reduce Production 17
'==' Reduce Production 17
'>' Reduce Production 17
'>=' Reduce Production 17
assign Reduce Production 17
display Reduce Production 17
do Reduce Production 17
else Reduce Production 17
end Reduce Production 17
if Reduce Production 17
read Reduce Production 17
then Reduce Production 17
while Reduce Production 17
Prior States
25

LALR State 42
Configuration Lookahead
<Add Exp> ::= <Add Exp> '+' <Mult Exp> · EOF - & ) + < <= <> == > >= assign display do else end if read then while
<Mult Exp> ::= <Mult Exp> · '*' <Negate Exp> EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
<Mult Exp> ::= <Mult Exp> · '/' <Negate Exp> EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
Actions
'*' Shift to State 34
'/' Shift to State 35
(EOF) Reduce Production 15
'-' Reduce Production 15
'&' Reduce Production 15
')' Reduce Production 15
'+' Reduce Production 15
'<' Reduce Production 15
'<=' Reduce Production 15
'<>' Reduce Production 15
'==' Reduce Production 15
'>' Reduce Production 15
'>=' Reduce Production 15
assign Reduce Production 15
display Reduce Production 15
do Reduce Production 15
else Reduce Production 15
end Reduce Production 15
if Reduce Production 15
read Reduce Production 15
then Reduce Production 15
while Reduce Production 15
Prior States
26

LALR State 43
Configuration Lookahead
<Expression> ::= <Expression> '<' <Add Exp> · EOF ) < <= <> == > >= assign display do else end if read then while
<Add Exp> ::= <Add Exp> · '+' <Mult Exp> EOF - & ) + < <= <> == > >= assign display do else end if read then while
<Add Exp> ::= <Add Exp> · '-' <Mult Exp> EOF - & ) + < <= <> == > >= assign display do else end if read then while
<Add Exp> ::= <Add Exp> · '&' <Mult Exp> EOF - & ) + < <= <> == > >= assign display do else end if read then while
Actions
'-' Shift to State 24
'&' Shift to State 25
'+' Shift to State 26
(EOF) Reduce Production 9
')' Reduce Production 9
'<' Reduce Production 9
'<=' Reduce Production 9
'<>' Reduce Production 9
'==' Reduce Production 9
'>' Reduce Production 9
'>=' Reduce Production 9
assign Reduce Production 9
display Reduce Production 9
do Reduce Production 9
else Reduce Production 9
end Reduce Production 9
if Reduce Production 9
read Reduce Production 9
then Reduce Production 9
while Reduce Production 9
Prior States
27

LALR State 44
Configuration Lookahead
<Expression> ::= <Expression> '<=' <Add Exp> · EOF ) < <= <> == > >= assign display do else end if read then while
<Add Exp> ::= <Add Exp> · '+' <Mult Exp> EOF - & ) + < <= <> == > >= assign display do else end if read then while
<Add Exp> ::= <Add Exp> · '-' <Mult Exp> EOF - & ) + < <= <> == > >= assign display do else end if read then while
<Add Exp> ::= <Add Exp> · '&' <Mult Exp> EOF - & ) + < <= <> == > >= assign display do else end if read then while
Actions
'-' Shift to State 24
'&' Shift to State 25
'+' Shift to State 26
(EOF) Reduce Production 10
')' Reduce Production 10
'<' Reduce Production 10
'<=' Reduce Production 10
'<>' Reduce Production 10
'==' Reduce Production 10
'>' Reduce Production 10
'>=' Reduce Production 10
assign Reduce Production 10
display Reduce Production 10
do Reduce Production 10
else Reduce Production 10
end Reduce Production 10
if Reduce Production 10
read Reduce Production 10
then Reduce Production 10
while Reduce Production 10
Prior States
28

LALR State 45
Configuration Lookahead
<Expression> ::= <Expression> '<>' <Add Exp> · EOF ) < <= <> == > >= assign display do else end if read then while
<Add Exp> ::= <Add Exp> · '+' <Mult Exp> EOF - & ) + < <= <> == > >= assign display do else end if read then while
<Add Exp> ::= <Add Exp> · '-' <Mult Exp> EOF - & ) + < <= <> == > >= assign display do else end if read then while
<Add Exp> ::= <Add Exp> · '&' <Mult Exp> EOF - & ) + < <= <> == > >= assign display do else end if read then while
Actions
'-' Shift to State 24
'&' Shift to State 25
'+' Shift to State 26
(EOF) Reduce Production 13
')' Reduce Production 13
'<' Reduce Production 13
'<=' Reduce Production 13
'<>' Reduce Production 13
'==' Reduce Production 13
'>' Reduce Production 13
'>=' Reduce Production 13
assign Reduce Production 13
display Reduce Production 13
do Reduce Production 13
else Reduce Production 13
end Reduce Production 13
if Reduce Production 13
read Reduce Production 13
then Reduce Production 13
while Reduce Production 13
Prior States
29

LALR State 46
Configuration Lookahead
<Expression> ::= <Expression> '==' <Add Exp> · EOF ) < <= <> == > >= assign display do else end if read then while
<Add Exp> ::= <Add Exp> · '+' <Mult Exp> EOF - & ) + < <= <> == > >= assign display do else end if read then while
<Add Exp> ::= <Add Exp> · '-' <Mult Exp> EOF - & ) + < <= <> == > >= assign display do else end if read then while
<Add Exp> ::= <Add Exp> · '&' <Mult Exp> EOF - & ) + < <= <> == > >= assign display do else end if read then while
Actions
'-' Shift to State 24
'&' Shift to State 25
'+' Shift to State 26
(EOF) Reduce Production 12
')' Reduce Production 12
'<' Reduce Production 12
'<=' Reduce Production 12
'<>' Reduce Production 12
'==' Reduce Production 12
'>' Reduce Production 12
'>=' Reduce Production 12
assign Reduce Production 12
display Reduce Production 12
do Reduce Production 12
else Reduce Production 12
end Reduce Production 12
if Reduce Production 12
read Reduce Production 12
then Reduce Production 12
while Reduce Production 12
Prior States
30

LALR State 47
Configuration Lookahead
<Expression> ::= <Expression> '>' <Add Exp> · EOF ) < <= <> == > >= assign display do else end if read then while
<Add Exp> ::= <Add Exp> · '+' <Mult Exp> EOF - & ) + < <= <> == > >= assign display do else end if read then while
<Add Exp> ::= <Add Exp> · '-' <Mult Exp> EOF - & ) + < <= <> == > >= assign display do else end if read then while
<Add Exp> ::= <Add Exp> · '&' <Mult Exp> EOF - & ) + < <= <> == > >= assign display do else end if read then while
Actions
'-' Shift to State 24
'&' Shift to State 25
'+' Shift to State 26
(EOF) Reduce Production 8
')' Reduce Production 8
'<' Reduce Production 8
'<=' Reduce Production 8
'<>' Reduce Production 8
'==' Reduce Production 8
'>' Reduce Production 8
'>=' Reduce Production 8
assign Reduce Production 8
display Reduce Production 8
do Reduce Production 8
else Reduce Production 8
end Reduce Production 8
if Reduce Production 8
read Reduce Production 8
then Reduce Production 8
while Reduce Production 8
Prior States
31

LALR State 48
Configuration Lookahead
<Expression> ::= <Expression> '>=' <Add Exp> · EOF ) < <= <> == > >= assign display do else end if read then while
<Add Exp> ::= <Add Exp> · '+' <Mult Exp> EOF - & ) + < <= <> == > >= assign display do else end if read then while
<Add Exp> ::= <Add Exp> · '-' <Mult Exp> EOF - & ) + < <= <> == > >= assign display do else end if read then while
<Add Exp> ::= <Add Exp> · '&' <Mult Exp> EOF - & ) + < <= <> == > >= assign display do else end if read then while
Actions
'-' Shift to State 24
'&' Shift to State 25
'+' Shift to State 26
(EOF) Reduce Production 11
')' Reduce Production 11
'<' Reduce Production 11
'<=' Reduce Production 11
'<>' Reduce Production 11
'==' Reduce Production 11
'>' Reduce Production 11
'>=' Reduce Production 11
assign Reduce Production 11
display Reduce Production 11
do Reduce Production 11
else Reduce Production 11
end Reduce Production 11
if Reduce Production 11
read Reduce Production 11
then Reduce Production 11
while Reduce Production 11
Prior States
32

LALR State 49
Configuration Lookahead
<Statement> ::= display <Expression> read Id · EOF assign display else end if while
Actions
(EOF) Reduce Production 3
assign Reduce Production 3
display Reduce Production 3
else Reduce Production 3
end Reduce Production 3
if Reduce Production 3
while Reduce Production 3
Prior States
33

LALR State 50
Configuration Lookahead
<Mult Exp> ::= <Mult Exp> '*' <Negate Exp> · EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
Actions
(EOF) Reduce Production 19
'-' Reduce Production 19
'&' Reduce Production 19
')' Reduce Production 19
'*' Reduce Production 19
'/' Reduce Production 19
'+' Reduce Production 19
'<' Reduce Production 19
'<=' Reduce Production 19
'<>' Reduce Production 19
'==' Reduce Production 19
'>' Reduce Production 19
'>=' Reduce Production 19
assign Reduce Production 19
display Reduce Production 19
do Reduce Production 19
else Reduce Production 19
end Reduce Production 19
if Reduce Production 19
read Reduce Production 19
then Reduce Production 19
while Reduce Production 19
Prior States
34

LALR State 51
Configuration Lookahead
<Mult Exp> ::= <Mult Exp> '/' <Negate Exp> · EOF - & ) * / + < <= <> == > >= assign display do else end if read then while
Actions
(EOF) Reduce Production 20
'-' Reduce Production 20
'&' Reduce Production 20
')' Reduce Production 20
'*' Reduce Production 20
'/' Reduce Production 20
'+' Reduce Production 20
'<' Reduce Production 20
'<=' Reduce Production 20
'<>' Reduce Production 20
'==' Reduce Production 20
'>' Reduce Production 20
'>=' Reduce Production 20
assign Reduce Production 20
display Reduce Production 20
do Reduce Production 20
else Reduce Production 20
end Reduce Production 20
if Reduce Production 20
read Reduce Production 20
then Reduce Production 20
while Reduce Production 20
Prior States
35

LALR State 52
Configuration Lookahead
<Statement> ::= if <Expression> then <Statements> · end EOF assign display else end if while
<Statement> ::= if <Expression> then <Statements> · else <Statements> end EOF assign display else end if while
Actions
else Shift to State 54
end Shift to State 55
Prior States
36

LALR State 53
Configuration Lookahead
<Statement> ::= while <Expression> do <Statements> · end EOF assign display else end if while
Actions
end Shift to State 56
Prior States
37

LALR State 54
Configuration Lookahead
<Statement> ::= if <Expression> then <Statements> else · <Statements> end EOF assign display else end if while
<Statements> ::= · <Statement> <Statements> end
<Statements> ::= · <Statement> end
<Statement> ::= · display <Expression> assign display end if while
<Statement> ::= · display <Expression> read Id assign display end if while
<Statement> ::= · assign Id '=' <Expression> assign display end if while
<Statement> ::= · while <Expression> do <Statements> end assign display end if while
<Statement> ::= · if <Expression> then <Statements> end assign display end if while
<Statement> ::= · if <Expression> then <Statements> else <Statements> end assign display end if while
Actions
assign Shift to State 1
display Shift to State 2
if Shift to State 3
while Shift to State 4
<Statement> Go to State 5
<Statements> Go to State 57
Prior States
52

LALR State 55
Configuration Lookahead
<Statement> ::= if <Expression> then <Statements> end · EOF assign display else end if while
Actions
(EOF) Reduce Production 6
assign Reduce Production 6
display Reduce Production 6
else Reduce Production 6
end Reduce Production 6
if Reduce Production 6
while Reduce Production 6
Prior States
52

LALR State 56
Configuration Lookahead
<Statement> ::= while <Expression> do <Statements> end · EOF assign display else end if while
Actions
(EOF) Reduce Production 5
assign Reduce Production 5
display Reduce Production 5
else Reduce Production 5
end Reduce Production 5
if Reduce Production 5
while Reduce Production 5
Prior States
53

LALR State 57
Configuration Lookahead
<Statement> ::= if <Expression> then <Statements> else <Statements> · end EOF assign display else end if while
Actions
end Shift to State 58
Prior States
54

LALR State 58
Configuration Lookahead
<Statement> ::= if <Expression> then <Statements> else <Statements> end · EOF assign display else end if while
Actions
(EOF) Reduce Production 7
assign Reduce Production 7
display Reduce Production 7
else Reduce Production 7
end Reduce Production 7
if Reduce Production 7
while Reduce Production 7
Prior States
57