An Animated Introduction to Clojure
by
Mark Mahoney
1 Introduction to Clojure
How to read this book*
Start Here!
Hello World!!!
Reading, evaluation, and arithmetic
Dog age converter
Java interoperability
Lists, vectors, maps, and sets
Efficient immutability
2 Clojure Functions
Basics of functions
Fizz Buzz
Maps as objects
Reading from a file (with CS Poetry)
Writing to a file
3 Closures
Closures
More closures with an interest calculator
4 Recursion
Tail recursion
Fizz Buzz with recursion
Square root with recursion
Mortgage schedule with recursion
5 Laziness
Laziness
Lazy primes (Fizz Buzz part 3)
Poker probablities with closures and lazy sequences
6 Macros
Macros
Macros for set operations
7 Threads and Concurrency
Threads
Poker probabilities with threads
Concurrency with
refs
Poker with
atoms
Asynchronous mutable data with agents
Simpler concurrency
Have you watched most of the playbacks?
Interested in giving me some feedback?
Here is an
anonymous, informal survey
that will let me know what you think.
Do you want to learn C++ programming with playbacks? Check out my other book of playbacks,
"An Animated Introduction to Programming with C++"
* (
Click here for some additional Storyteller documentation
)