Hacker News new | ask | show | jobs
by lrc 3966 days ago
I've spent a lot of time with SICP and with Clojure. The book changed my life, and I too considered working on "porting" the book, but there would be a considerable amount of friction. Clojure can do everything necesssary, but it's very unidiomatic to build data structures out of pairs in Clojure, and SICP spends a _lot_ of time implementing data structures with pairs. A reconsideration of SICP for the modern age would, I think, take vectors and maps and sets as given, and see what _additional_ magic could be built from there!

Just start with sequences. Lazy sequences, which are so helpful in the expert system database that's built in SICP, are already right there in Clojure without the complications of force and delay. My thought is you could do a lot more with the higher level examples, but a lot of the first half of the book would have to be rethought. (The functional implementation of Conway's Life in O'Reilly's "Clojure Programming" is as good as anything in the first third of SICP, for example; the example of accelerating series convergence from SICP seems less exciting today than it used to, at least to me.)