Live data from Hacker News

Writing an Interpreter in Go: The Paperback Edition

thorstenball.com

11–20 of 78 posts

Re: Writing an Interpreter in Go: The Paperback Edition

#12
post #11

So what was the source format? Markdown?

Yes. 5-6 markdown files, converted to epub, mobi, pdf and html with pandoc. I know there are better workflows, especially in regards to embedding code (my approach was simple copy and paste), but if there's one recommendation I can make it's this one: check out pandoc. It's an amazing tool.

Re: Writing an Interpreter in Go: The Paperback Edition

#14
post #10

It is becoming quite popular (or maybe it was always the case?) that someone learning some topic and at the same time writing a book about it. Interesting how it affects the quality of the content (versus books authored by persons with expertise in given topics).

I tend not to put those two "kinds" of books in same category. I read them with hope to achieve different goals. They aren't read in the same way, but I think that is normal considering those two types.

Re: Writing an Interpreter in Go: The Paperback Edition

#17
post #10

It is becoming quite popular (or maybe it was always the case?) that someone learning some topic and at the same time writing a book about it. Interesting how it affects the quality of the content (versus books authored by persons with expertise in given topics).

My belief is that writing about a topic that one is trying to come to grips with helps ensure they achieve the best possible learning outcomes.

Re: Writing an Interpreter in Go: The Paperback Edition

#18

Anyone can share what sort of interpreter this is? Is it a walking-AST kind of thing, or something more advanced?

It's a AST walking interpreter, completely built from scratch, including the lexer, the parser, the AST and, of course, the walking/evaluation step.

Re: Writing an Interpreter in Go: The Paperback Edition

#19
post #10

It is becoming quite popular (or maybe it was always the case?) that someone learning some topic and at the same time writing a book about it. Interesting how it affects the quality of the content (versus books authored by persons with expertise in given topics).

My belief is that writing about a topic that one is trying to come to grips with helps ensure they achieve the best possible learning outcomes.

The best learning outcomes for the author I believe. But I'm more interested in the prospective reader's PoV.

Re: Writing an Interpreter in Go: The Paperback Edition

#20
post #19

Earlier quoted context omitted.

My belief is that writing about a topic that one is trying to come to grips with helps ensure they achieve the best possible learning outcomes.

The best learning outcomes for the author I believe. But I'm more interested in the prospective reader's PoV.

I think it's probably both, once you know a subject well it's easy to take some of that knowledge for granted. If you have just learnt it then you probably have a little more empathy for the reader.
Post reply on HN