orangeduck / BuildYourOwnLisp

Learn C and build your own programming language in under 1000 lines of code!
http://www.buildyourownlisp.com/
Other
2.84k stars 392 forks source link

Fix reverse polish conversion #143

Open PTrottier opened 4 years ago

PTrottier commented 4 years ago

The reverse polish notation equivalent for 1 + 2 + 6 looked off to me, so I checked with: https://raj457036.github.io/Simple-Tools/prefixAndPostfixConvertor.html

Indeed, it should be + + 1 2 6 (it is missing an operator)

orangeduck commented 4 years ago

While this is technically true I think in the case of this book the current text is more clean in explaining how it works.

PTrottier commented 4 years ago

Ok, sounds good, feel free to close this. Thanks for your dedication to the book, it is truly a splendid resource.

PTrottier commented 4 years ago

Or perhaps the example could be simpler, just + 1 2, so that it remains correct and is easier to grasp.