Chapter 2. The Clojure Environment

"Hello World" in Clojure

To start programming in Clojure immediately, simply open a Clojure REPL, which stands for Read Evaluate Print Loop. The REPL is a simple yet powerful way to create programs interactively as well as interact with already running programs.

The simplest way to start the REPL is to start it directly from the system command line[3]. To do this, navigate to the system directory where you have installed Clojure, the one that contains the "clojure-1.0.0.jar" file. Then type the following to start Clojure:

java -jar clojure-1.0.0.jar

This starts up the Java virtual machine and loads the Clojure environment. As soon as the REPL comes up, you should see the following prompt:

user=>

This indicates that ...

Get Practical Clojure now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.