Chapter 1. Introduction to Clojure

 

This chapter covers

  • Clojure basics
  • What makes Clojure special
  • Clojure as a Lisp
  • Clojure as a functional programming language
  • Clojure as a JVM-based language

The greatest single programming language ever designed.

Alan Kay on Lisp

Lisp is worth learning for the profound enlightenment experience you will have when you finally get it; that experience will make you a better programmer for the rest of your days, even if you never use Lisp itself a lot.

Eric Raymond

Any sufficiently complicated C or Fortran program contains an ad hoc, informally specified, bug-ridden, slow implementation of half of Common Lisp.

Philip Greenspun

1.1. What is Clojure?

Clojure is a new programming language, designed as a fresh take on Lisp, one of the oldest programming languages still in active use (it’s the second oldest; only Fortran is older). Why would anyone want to learn something associated with such old technology? It turns out that although the answer is obvious to someone who already knows Lisp, it can’t be explained without some background. This chapter attempts to provide that background.

1.2. Understanding Clojure syntax

1.3. The sources of Clojure’s power

1.4. Clojure—beyond object orientation

1.5. Summary