8 ms·
Beautiful Racket
- ketralnis 9y agoI really like this book and highly recommend it. My only complaint is that because it is so directed (you're writing a programming language and it wants to get you there very quickly) it abstracts a lot of stuff that you'll need to know if you're doing anything other than following this book. For instance, a lot of the code you write will start with #lang br Instead of the usual Racket #lang racket That's using some support from Racket where you say "I'm writing the `br` language" and Racket goes and runs your code in that language instead of Racket. That "language" is really just Racket with some libraries pre-included (https://beautifulracket.com/appendix/from-br-to-racket-base.html https://beautifulracket.com/appendix/from-br-to-racket-base....) and some of those libraries are specific to the book (e.g. https://docs.racket-lang.org/br/index.html?q=br#%28mod-path._br%2Fsyntax%29 https://docs.racket-lang.org/br/index.html?q=br#%28mod-path....). So if you're following along the book, the upside is that that he can skip explaining a bunch of stuff about Racket packaging and libraries. But the downside is that he skips explaining a bunch of stuff about Racket packaging and libraries. If you want to take what you've learnt here and go write a programming language in Racket, you're going to have to go and learn all of that stuff anyway. You're going to have to take apart `br` and figure out how to map its parsing stuff to Racket's and you'll find that almost none of the scaffolding from the book can be copy-pasted without including the book's libraries, and many of the concepts aren't even reuseable if you want to use Racket's parsing tools instead of the book's largely bespoke tools. (Just including the book's libraries themselves can be difficult because of how Racket's packaging works. In the New World of Racket packaging, you install a library _on your machine_, not as a dependency of your project. So if you want to run your code on another machine, you first have to manually install the library on that machine before your code can run, and Racket's tooling around this is currently very sub-par.) But I'll say again that it's a great book and if you're interested in Lisp and Scheme in particular, you should buy it and you should read it. It's great. Just know that you'll have to read the book _and also learn Racket_.
- threatofrain 9y agoOn the matter of learning Racket, I've heard some good things about How to Design Programs (2nd Edition): http://www.ccs.neu.edu/home/matthias/HtDP2e/index.html http://www.ccs.neu.edu/home/matthias/HtDP2e/index.html.
- wikibob 9y agoThe approach in this book is one of if not the best in computer science pedagogy. This book specifically is in need of significant editing. As an alternative, see the incredibly good “How To Code” class from UBCx on EdX (don’t be put off by the title). It’s a direct implementation of the approach in this book.
- klibertp 9y agoI'd say HtDP is a good book for learning programming, but I don't think it's the best introduction to Racket. It also uses a specially crafted languages (a series of them) and focuses on the process of coming up and implementing the design, while removing most of the usual problems (cryptic error messages, too complex docs, too advanced techniques) which the beginners encounter. It's great as an introduction to programming, and it's even worthwhile a quick read for more experienced programmers (esp. self-taught), but it's definitely not about learning Racket, at all. The Little Schemer may be slightly better, but on its own, it too is not about learning Racket. Actually, I guess there's no book about Racket itself (EDIT: other than this one to some extent (in "explainers")) - existing books either focus on the basics of programming (HtDP, Realm of Racket) or on specific algorithmic problems and techniques (The X Schemer, SICP). Which is kind of natural given the educational background, but it makes it harder for already established programmers to learn Racket to get the job done.
- Sinidir 9y agoExactly my thoughts the last time i looked at learning resources in respect to Racket.
- Scarbutt 9y agoAfter you have read HtDP2e, I found that racket-lang.org has all you need. The Little Schemer may be slightly better, but on its own, it too is not about learning Racket. Although they overlap on some topics, comparing little schemer to htdp is comparing apples to oranges. Also, htdp is just racket in my opinion, it differs very little from the students languages, I did the whole thing using just plain racket and didn't have any problems that couldn't be solved in two minutes visiting docs.racket-lang.org (and they were rare), but sure, you won't get to know all of racket because that's not the point of the book.
- weberc2 9y agoLooks like it's being hugged to death.
- laCour 9y agoArchive link: https://web.archive.org/web/20180509201622/https://beautifulracket.com/ https://web.archive.org/web/20180509201622/https://beautiful...
- _hardwaregeek 9y agoPractical Typography (written by the same author) has been a wonderful resource for me. Sometime I'll get around to working through this book as well. My high school is actually one of the last places to teach Racket/Scheme as an introductory language. Personally I find it a wonderful way of teaching the basics of computation and recursion. I wish more schools still taught it.
- rachitnigam 9y agoSeveral universities still teach racket as an intro language. Ex: Brown, Northeastern, Northwestern, etc. The authors of Racket specially avoid arguments about teaching language X in introductory CS. The pedagogy and curriculum are significantly more factors in effectively teaching CS [1]. The design of Racket with its restricted languages reflects that. [1] https://www.janestreet.com/tech-talks/curriculum-design/ https://www.janestreet.com/tech-talks/curriculum-design/
- adjkant 9y agoThis is an essay by the creator/author of How To Design Programs (currently at Northeastern) that lays out the pedagogy well: http://www.ccs.neu.edu/home/matthias/Thoughts/Developing_Developers.html http://www.ccs.neu.edu/home/matthias/Thoughts/Developing_Dev... The speaker in the talk linked is a previous Ph.D. student of the author above. Northeastern, Brown, Northwestern, and Waterloo all use the approach in HTDP as far as I'm aware, even if they don't use the book itself. Racket just happens to be the language of choice (or rather X Student Languages are, not even Racket) because they fit the pedagogy well.
- finolex1 9y agoYale's intro CS class uses Racket: https://zoo.cs.yale.edu/classes/cs201/ https://zoo.cs.yale.edu/classes/cs201/
- lightedman 9y ago"Practical Typography (written by the same author) has been a wonderful resource for me." Yet his webpage fonts give me an absolute headache. That doesn't give me a good gut feeling about "Beautiful Racket."
- bgorman 9y agoThis is a very interesting case where the author claims the book is not free, provides it on a public webpage, and does not want to provide a PDF or ePub. I would gladly be willing to pay for content, but I like to do most of my reading on a kindle. I am not willing to pay for a book if the author is trying to make it as difficult as possible to view his book (but at least the fonts are beautiful).
- phren0logy 9y agoPart of the justification (which you may or may not buy) is that it's not intended to be viewed as static content. Therefore, a PDF or eBook is not an appropriate medium.
- deleted 9y ago[deleted]
- criddell 9y agoThat makes sense to me but then I think the book needs a track changes feature. It might be there, but the site was loading slowly enough that I didn't really explore.
- criddell 9y agoYour Kindle has rudimentary web browser, you might be able to read it there.
- chipotle_coyote 9y agoButterick has Strong Opinions™ about Kindle typography that led him to that position. I largely share those opinions, to be fair, although I think it's a bit of a quixotic enterprise for many books; offline is more important than beauty. (And, really, the Kindle could do most of these tricks if Amazon gave a rat's ass; Apple's iBooks can do nearly everything that any other WebKit browser can with regards to typography.) Having said that, though, this is a book that I'd argue is better in the browser than on the Kindle or as a PDF. I want to be able to read this with a code editor open, and the book side-by-side in a separate window. PDF books don't reflow, and in my experience Kindle just isn't particularly good for tech books.
- adjkant 9y agoThis is a great introduction to Racket as a language for building languages. For those interested further, there is a lot of work with Racket in this respect. A recent paper previously hit the front page of HN on "Domain Specific Languages" (DSL's), which is basically the idea that you should write a programming language for each problem to make it easier to write programs in that domain rather than writing complex spaghetti code in a general-purpose language or writing a library that badly ports to the general purpose language. I'm a bit biased here, but I think this could be the next big step in programming in the next few decades as we see people not writing libraries but writing DSL's to make for easy writing of programs. HN Discussion: https://news.ycombinator.com/item?id=16454854 https://news.ycombinator.com/item?id=16454854 The authors of the paper are mentioned in the acknowledgments of this book as well!
- grimgrin 9y agoHere's a cache of A Programmable Programming Language since it's down for me atm https://webcache.googleusercontent.com/search?q=cache:ATgZRmeSNKAJ:https://cacm.acm.org/magazines/2018/3/225475-a-programmable-programming-language/fulltext+&cd=1&hl=en&ct=clnk&gl=us https://webcache.googleusercontent.com/search?q=cache:ATgZRm...
- verdverm 9y agore: Programming in DSLs I'm working on an engine for this https://geb.hofstadter.io https://geb.hofstadter.io
- gergoerdi 9y agoAnd here's a worked example of applying this approach, in this case to the domain of video editing: Super 8 Languages for Making Movies (Functional Pearl) https://www2.ccs.neu.edu/racket/pubs/icfp17-acf.pdf https://www2.ccs.neu.edu/racket/pubs/icfp17-acf.pdf
- mathinpens 9y agowhat a beautiful book.
- cherylann50 9y agoMy husband was cheating on me with a lady at work. I wasn't sure unti someone told me about reliablehacker2017 AT G MAIL DOT COM. I contacted him and he cloned his phone and whatsapp and I could see all he was doing behind my back. It hurts but I know the truth now. You can contact him to work for you. And thank me later
- nanomonkey 9y agoHow useful is this book for a Clojure programmer? I always wonder if there is cross-over in practices between the Lisps.
- wvlia5 9y agoI have little knowledge of lisps, but I'd like to implement a new language in one of them. What would be a better choice, racket or clojure?
- thelibrarian 9y agoOne of Racket’s is explicit design goals is to be a toolkit for designing and implementing new languages, so I would say it is the better choice.
- wvlia5 9y agoYes I know, but I've heard some clojurists criticizing racket because of its data structures. So perhaps that would outweigh its benefits. Thanks for your opinion
- watersb 9y agoOther fantastic projects by the same author: “Typography for Lawyers” https://typographyforlawyers.com/ https://typographyforlawyers.com/ “The Book is a Program” https://docs.racket-lang.org/pollen/ https://docs.racket-lang.org/pollen/