Clojure

Getting Started

What tools do I need?

Clojure is a dynamic development environment where you interact with your program while you write it, growing and adding to it while it’s running. To work with Clojure you need an editor that supports evaluation in source files and structural editing (working with nested forms in addition to character editing).

Install these first:

  • Clojure provides the language, a REPL (Read Eval Print Loop), library support, and program runner

  • Editor with interactive development support

How do I work with these tools?

The details will depend on your operating system and editor but the essential flow for all of them is the same:

  • Create or open a file

  • Connect a Clojure environment (aka the REPL)

  • Write Clojure code in your editor

  • Evaluate the code in your editor using the connected environment

  • Repeat!

Learn more:

  • REPL - learn more about the REPL and how to use it interactively

  • Structural editing - working with code as forms, not text

How do I learn the language?

There are many ways to learn the Clojure language. This tutorial covers the basics:

If you’d like to work from a book, these are some excellent starting points:

Programming Clojure 3rd edition Getting Clojure Clojure for the Brave and True Living Clojure

If you’d like to try some practice problems:

Also check out:

Where can I ask questions?

There are many places to interact with other Clojure developers:

Original author: Alex Miller