O'Reilly logo

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

The Joy of Clojure, 2nd Edition, Video Edition

Video Description

"A cornucopia of programming concepts."
William E. Byrd and Daniel P. Friedman, authors of "The Reasoned Schemer"

The Joy of Clojure, Second Edition is a deep account of the Clojure language. Fully updated for Clojure 1.6, this edition goes beyond the syntax to show you how to write fluent Clojure code. You'll learn functional and declarative approaches to programming and will master techniques that make Clojure elegant and efficient. The book shows you how to solve hard problems related to concurrency, interoperability, and performance, and how great it can be to think in the Clojure way.

The Clojure programming language is a dialect of Lisp that runs on the Java Virtual Machine and JavaScript runtimes. It is a functional programming language that offers great performance, expressive power, and stability by design. It gives you built-in concurrency and the predictable precision of immutable and persistent data structures. And it's really, really fast. The instant you see long blocks of Java or Ruby dissolve into a few lines of Clojure, you'll know why the authors of this book call it a "joyful language." It's no wonder that enterprises like Staples are betting their infrastructure on Clojure.
Inside:

  • Build web apps using ClojureScript
  • Master functional programming techniques
  • Simplify concurrency
  • Covers Clojure 1.6
Michael Fogus and Chris Houser are contributors to the Clojure and ClojureScript programming languages and the authors of various Clojure libraries and language features.

Clojure changes the way we think about programming—this book changes the way we think about Clojure.
Cristofer Weber, NeoGrid

Clear examples for both novice and experienced programmers.
Jasper Lievisse Adriaanse, M:Tier

A joy to read. I couldn't put it down.
Heather Campbell, Kainos

NARRATED BY MARK THOMAS

Table of Contents

  1. Part 1. Foundations
    1. Chapter 1. Clojure philosophy 00:08:04
    2. Chapter 1. Clarity 00:05:17
    3. Chapter 1. Why a(nother) Lisp? 00:07:09
    4. Chapter 1. But what’s with all the parentheses? 00:07:37
    5. Chapter 1. Functional programming 00:03:11
    6. Chapter 1. Why Clojure isn’t especially object-oriented 00:04:45
    7. Chapter 1. Most of what OOP gives you, Clojure provides 00:11:28
    8. Chapter 2. Drinking from the Clojure fire hose 00:06:08
    9. Chapter 2. Floating-point numbers 00:03:42
    10. Chapter 2. Putting things together: collections 00:04:12
    11. Chapter 2. Making things happen: calling functions 00:06:24
    12. Chapter 2. Functions with multiple arities 00:03:20
    13. Chapter 2. Locals, loops, and blocks 00:08:45
    14. Chapter 2. Preventing things from happening: quoting 00:08:34
    15. Chapter 2. Using host libraries via interop 00:06:31
    16. Chapter 2. Exceptional circumstances 00:08:15
    17. Chapter 3. Dipping your toes in the pool 00:05:29
    18. Chapter 3. Nil pun with care 00:08:26
    19. Chapter 3. Destructuring with a map 00:05:25
    20. Chapter 3. Using the REPL to experiment 00:07:39
    21. Chapter 3. Putting it all together 00:07:07
  2. Part 2. Data types
    1. Chapter 4. On scalars 00:09:47
    2. Chapter 4. Trying to be rational 00:05:09
    3. Chapter 4. When to use keywords 00:06:23
    4. Chapter 4. Symbolic resolution 00:06:19
    5. Chapter 4. Regular expressions—the second problem 00:06:39
    6. Chapter 5. Collection types 00:04:26
    7. Chapter 5. Sequence terms and what they mean 00:07:47
    8. Chapter 5. Big-O 00:05:12
    9. Chapter 5. Vectors: creating and using them in all their varieties 00:09:39
    10. Chapter 5. Vectors as stacks 00:05:34
    11. Chapter 5. Vectors as map entries 00:05:21
    12. Chapter 5. Lists: Clojure’s code-form data structure 00:06:42
    13. Chapter 5. How to use persistent queues 00:05:22
    14. Chapter 5. Persistent sets 00:08:01
    15. Chapter 5. Thinking in maps 00:08:23
    16. Chapter 5. Putting it all together: finding the position of items in a sequence 00:05:55
  3. Part 3. Functional programming techniques
    1. Chapter 6. Being lazy and set in your ways 00:07:31
    2. Chapter 6. Structural sharing: a persistent toy 00:07:35
    3. Chapter 6. Laziness 00:09:26
    4. Chapter 6. Losing your head 00:08:07
    5. Chapter 6. Putting it all together: a lazy quicksort 00:06:34
    6. Chapter 7. Functional programming 00:09:23
    7. Chapter 7. Higher-order functions 00:07:23
    8. Chapter 7. Pure functions 00:08:22
    9. Chapter 7. On closures 00:07:49
    10. Chapter 7. Sharing closure context 00:06:59
    11. Chapter 7. Thinking recursively 00:06:30
    12. Chapter 7. Tail calls and recur 00:06:15
    13. Chapter 7. Don’t forget your trampoline 00:08:13
    14. Chapter 7. Putting it all together: A* pathfinding 00:08:55
  4. Part 4. Large-scale design
    1. Chapter 8. Macros 00:07:09
    2. Chapter 8. Syntax-quote, unquote, and splicing 00:05:18
    3. Chapter 8. Defining control structures 00:05:44
    4. Chapter 8. Macros combining forms 00:09:07
    5. Chapter 8. Using macros to control symbolic resolution time 00:07:10
    6. Chapter 8. Using macros to manage resources 00:08:01
    7. Chapter 9. Combining data and code 00:05:43
    8. Chapter 9. Expose only what’s needed 00:06:19
    9. Chapter 9. Exploring Clojure multimethods with the Universal Design Pattern 00:07:17
    10. Chapter 9. Ad hoc hierarchies for inherited behaviors 00:05:17
    11. Chapter 9. Types, protocols, and records 00:07:13
    12. Chapter 9. Protocols 00:09:21
    13. Chapter 9. Sharing method implementations 00:08:11
    14. Chapter 9. Building from a more primitive base with deftype 00:05:42
    15. Chapter 9. Clojure implementation 00:05:29
    16. Chapter 10. Mutation and concurrency 00:09:14
    17. Chapter 10. Using refs for a mutable game board 00:07:45
    18. Chapter 10. The things that STM makes easy 00:07:06
    19. Chapter 10. Refactoring with refs 00:05:59
    20. Chapter 10. Vulgar change with ref-set 00:05:44
    21. Chapter 10. When to use agents 00:09:09
    22. Chapter 10. The difference between send and send-off 00:08:43
    23. Chapter 10. When to use atoms 00:06:40
    24. Chapter 10. When to use locks 00:08:06
    25. Chapter 10. Vars and dynamic binding 00:07:26
    26. Chapter 10. Dynamic scope 00:04:44
    27. Chapter 11. Parallelism 00:02:58
    28. Chapter 11. Futures as callbacks 00:08:13
    29. Chapter 11. When to use promises 00:06:00
    30. Chapter 11. Parallel operations 00:04:18
    31. Chapter 11. A brief introduction to reducer/fold 00:03:41
  5. Part 5. Host symbiosis
    1. Chapter 12. Java.next 00:04:50
    2. Chapter 12. A simple dynamic web service 00:08:31
    3. Chapter 12. Anaphoric proxy 00:05:07
    4. Chapter 12. Clojure gen-class and GUI programming 00:09:43
    5. Chapter 12. Clojure’s relationship to Java arrays 00:08:29
    6. Chapter 12. All Clojure functions implement ... 00:04:23
    7. Chapter 12. Using Clojure data structures in Java APIs 00:06:03
    8. Chapter 12. The definterface macro 00:02:48
    9. Chapter 12. Be wary of exceptions 00:06:23
    10. Chapter 12. Handling exceptions 00:05:18
    11. Chapter 13. Why ClojureScript? 00:09:38
    12. Chapter 13. Compiler internals: analysis vs. emission 00:05:40
    13. Chapter 13. Web Audio 00:06:56
    14. Chapter 13. Advanced compilation 00:05:59
    15. Chapter 13. Generating an externs.js file 00:04:26
    16. Chapter 13. Compile vs. run 00:13:00
  6. Part 6. Tangential considerations
    1. Chapter 14. Data-oriented programming 00:05:58
    2. Chapter 14. Common ways to derive information from data 00:04:32
    3. Chapter 14. Data as data 00:08:18
    4. Chapter 14. The benefits of value 00:04:22
    5. Chapter 14. Tagged literals 00:09:33
    6. Chapter 14. Data as code 00:03:38
    7. Chapter 14. Case study: simple event sourcing 00:04:33
    8. Chapter 14. Simulation testing 00:10:51
    9. Chapter 14. Code as data as code 00:02:23
    10. Chapter 14. Putting parentheses around the specification 00:08:00
    11. Chapter 15. Performance 00:07:02
    12. Chapter 15. Transients 00:04:44
    13. Chapter 15. Chunked sequences 00:03:24
    14. Chapter 15. Memoization 00:07:46
    15. Chapter 15. Understanding coercion 00:09:18
    16. Chapter 15. Reducibles 00:08:00
    17. Chapter 15. More reducing function transformers 00:06:03
    18. Chapter 15. Performance of reducibles 00:07:31
    19. Chapter 15. The fold function: reducing in parallel 00:08:09
    20. Chapter 16. Thinking programs 00:07:58
    21. Chapter 16. A brute-force Sudoku solver 00:04:52
    22. Chapter 16. Thinking data via unification 00:10:42
    23. Chapter 16. Substitution 00:03:44
    24. Chapter 16. An introduction to core.logic 00:10:07
    25. Chapter 16. Subgoals 00:06:30
    26. Chapter 16. Constraints 00:05:39
    27. Chapter 16. Solving Sudoku with finite domains 00:08:06
    28. Chapter 17. Clojure changes the way you think 00:06:33
    29. Chapter 17. Implementing a SQL-like DSL to generate queries 00:12:49
    30. Chapter 17. Testing 00:06:37
    31. Chapter 17. Contracts programming 00:04:08
    32. Chapter 17. Invisible design patterns 00:05:45
    33. Chapter 17. Clojure’s first-class design patterns 00:05:14
    34. Chapter 17. Iterator pattern 00:08:55
    35. Chapter 17. Error handling and debugging 00:04:29
    36. Chapter 17. Debugging 00:08:48