Hacker News new | ask | show | jobs
by pona-a 666 days ago
Racket and Clojure are, in my opinion, well-designed, pragmatic languages that get to the point quickly and elegantly.

Clojure is a great opinionated functional language with a healthy ecosystem and a real job market. I now solve Advent of Code-style puzzles mainly in Clojure. Its only significant drawback, which is also its biggest feature, is the JVM. While it gives you interop with Java's ecosystem and lets you benifit from one of the fastest GC runtimes, it can leak its quirks into your program.

If interpreter start-up times are a concern, Babashka is an alternative Clojure interpreter based on GraalVM, with a startup time of about 30ms, making it perfect for UNIX scripting with a real programming language. For browser or Node dev, ClojureScript is an official dialect with a few minimal compromises given its runtime.

It also includes many useful additions like Actor concurrency model, transducers, multimethods, records, and EDN (Extendible Data Notation).

The only real objection is that Clojure isn't quite a Lisp, deviating from the definition in key ways, such as not using cons cells. However, this is not a concern outside an educational context.

Racket is essentially a modern Scheme dialect, adding many of its own niceties while not strictly following RnRS standards. It has an excellent contract typing system, #lang feature that allows you to define your own DSLs, tools for lazy and reactive programming, and a batteries-included standard library with plotting, GUI, statistics, and more, all while still being a true Scheme, which igves you other neat features like numerical tower, TCO, first class continuations, and with #lang and other interop tools, the ability to reuse run most normal Scheme code. Fun fact: HackerNews is written in Arc, a Lisp dialect, now implemented as within Racket.

Both languages have uniquely excellent documentation, use the regular and flexible syntax of S-expressions, and possess powerful macro systems. Both are equally useful and fun tools.