The Racket language belongs to the LISP family. The main difference between LISP and other languages is that you can name like-this, as opposed to likeThis (or, even worse, like_this), and all operators all prefix. That and homoiconicity. Homoiconicity is a fancy name for “code as data”, i.e., LISP code can be manipulated as any other data structure. Such manipulation is achieved by the use of macros- functions that receive code and output code, which in some cases might as well be black magic.
But let’s not get ahead of ourselves. Shall we begin with a simple function?
We have here a highlight of some nice Racket features: named let construct, which declares a function and subsequently calls it; arity based function dispatch with case-lambda; and the convention of defining functions to operate on different arities, say, + 2 3 or + 2 3 4 5 6 7 (see also apply, the ultimate uncurryer). We can also, however, see the horrible features: everything sort of blends together since the syntax is so regular; sometimes, deeply nested ))))), which you will get with let, let* and their friends, are next to impossible to digest. But simple-function is just the foldl function renamed. Can we get something more spicy?
define-syntax is the same as define, only for macros. The reader, who always completes all parts noted with “left as exercise to the reader”, have it already figured out for sure and thus must be getting bored. More examples?
Multiple returns are really neat, huh? What about pattern matching as a library (take that, Haskell)?
In conclusion, Racket is a nice, expressive, ultra dynamic LISP with Super Cow Powers. I recommend reading the official racket repository, whence all our examples were taken, as a starting guide.