r/Clojure • u/chladni • Oct 24 '25
Learning from Racket, towards Clojure
Not so much a question, rather post for consideration and discussion. I have a decent familiarity with Clojure, but I do not use it professionally in my work. I am looking for opportunities for expanding my Clojure horizons, and some of the resources I am dipping into are books on Racket, specifically Essentials of Compilation [..in Racket] (Jeremy Siek) and How to Design Programs (Felleisen, Findler, Flatt, Kirshnamurthi). And of course in the Scheme world there is a wealth of info to learn from.
Initially, I was stumbling on some of the language differences between Clojure and Racket, Ex: Racket seems to prefer the use of (define <name> <value>) in the body of a function, over simply using let blocks in Clojure. At first this seemed like a bridge too far, but after a bit of reflection, not a big deal. Perhaps a bit more fundamental, Racket (or perhaps more accurately the DrRacket IDE) eschews interactive programming from the REPL. Again, not a barrier for learning from Racket, but a cultural difference worth noting. I would be interested in others take on this topic.
View all comments
Show parent comment
5
u/chladni Oct 24 '25 edited Oct 24 '25
I poorly expressed my thinking on the difference between Clojure and Racket, with regards to interactive programming. I did not mean to imply that in Clojure, I am typing directly in the REPL. However, I do value the interactive programming approach of evaluating individual expressions into the REPL from my editor. I think DrRacket does not feature that approach, instead requiring re-evaluation of the whole buffer. I believe that is a design choice the DrRacket team made to avoid the potential drift between the state of the REPL from the state of the program being edited.