25 Feb 2013

Witness the might of lazy evaluation:

(require '[library.reference-section :as reference])

(def complete-works-of-shakespeare
  (filter #(= reference/complete-works-of-shakespeare %)
          (map typing (repeat monkey))))

Thanks to lazy evaluation, an infinite number of monkeys can be easily evaluated, even in memory-constrained environments1.

  1. This technique can be used for any body of text for which you already have a reference copy. 

comments powered by Disqus