Skip to Main Content
The Joy of Clojure, Second Edition
book

The Joy of Clojure, Second Edition

by Michael Fogus, Chris Houser
May 2014
Intermediate to advanced content levelIntermediate to advanced
520 pages
17h 23m
English
Manning Publications
Content preview from The Joy of Clojure, Second Edition

Chapter 6. Being lazy and set in your ways

This chapter covers

  • Immutability
  • Designing a persistent toy
  • Laziness
  • A lazy quicksort

We mentioned in section 1.3 that the definitions of functional programming are widely disparate, and unfortunately this book won’t work to unify them. Instead, we’ll start in this chapter to build a basis for Clojure’s style of functional programming by digging into its core supporting maxims: immutable data and laziness. In addition, this chapter covers in greater depth the parts of Clojure’s composite types that we’ve only touched on. It will conclude with a sorting function that uses both maxims in a way we find to be mentally invigorating.

6.1. On immutability: being set in your ways

We’ve touched on immutability ...

Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Living Clojure

Living Clojure

Carin Meier
Clojure in Action, Second Edition

Clojure in Action, Second Edition

Amit Rathore, Francis Avila
Getting Clojure

Getting Clojure

Russ Olsen
Programming Clojure, 3rd Edition

Programming Clojure, 3rd Edition

Alex Miller, Stuart Halloway, Aaron Bedra

Publisher Resources

ISBN: 9781617291418Supplemental ContentPublisher SupportOtherPublisher WebsiteSupplemental ContentPurchase Link