Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Edit question 2.3.3. Add brackets to minus. #186

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
37 changes: 37 additions & 0 deletions ch02/2.2/rom
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
head->X
sub->sub|head
low->head|headhead|headheadhead
subed->L|C
mid->C
lh->low
hh->midlow
tens->lh|hh|headsubed|e

head->I
sub->sub|head
low->head|headhead|headheadhead
subed->V|X
mid->V
lh->low
hh->midlow
ones->lh|hh|headsubed|e

head->C
sub->sub|head
low->head|headhead|headheadhead
subed->M|D
mid->D
lh->low
hh->midlow
hundrs->lh|hh|headsubed|e

head->M
low->head|headhead|headheadhead
thouth->low|e

rim->thouth_hundrs_ones





2 changes: 1 addition & 1 deletion ch02/2.3/2.3.md
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ translation schemes:

```
expr -> expr {print("+")} expr +
| expr {print("-")} expr -
| expr {print("-(")} expr {print(")"} -
| {print("(")} expr {print(")*(")} expr {print(")")} *
| {print("(")} expr {print(")/(")} expr {print(")")} /
| digit {print(digit)}
Expand Down