Open main menu
Home
Random
Recent changes
Special pages
Community portal
Preferences
About Wikipedia
Disclaimers
Incubator escapee wiki
Search
User menu
Talk
Dark mode
Contributions
Create account
Log in
Editing
LR parser
(section)
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
=== Parsing steps === The table below illustrates each step in the process. Here the state refers to the element at the top of the stack (the right-most element), and the next action is determined by referring to the action table above. A $ is appended to the input string to denote the end of the stream. {| class="wikitable" ! State ! Input stream ! Output stream ! Stack ! Next action |- | 0 | 1 + 1 $ | | [0] | Shift 2 |- | 2 | + 1 $ | | [0,2] | Reduce 5 |- | 4 | + 1 $ | 5 | [0,4] | Reduce 3 |- | 3 | + 1 $ | 5,3 | [0,3] | Shift 6 |- | 6 | 1 $ | 5,3 | [0,3,6] | Shift 2 |- | 2 | $ | 5,3 | [0,3,6,2] | Reduce 5 |- | 8 | $ | 5,3,5 | [0,3,6,8] | Reduce 2 |- | 3 | $ | 5,3,5,2 | [0,3] | Accept |}
Edit summary
(Briefly describe your changes)
By publishing changes, you agree to the
Terms of Use
, and you irrevocably agree to release your contribution under the
CC BY-SA 4.0 License
and the
GFDL
. You agree that a hyperlink or URL is sufficient attribution under the Creative Commons license.
Cancel
Editing help
(opens in new window)