2010-02-06 16:49:53 +00:00
|
|
|
(ns koans.path-to-enlightenment
|
|
|
|
|
(:use clojure.test))
|
2010-01-24 03:28:43 +00:00
|
|
|
|
2010-02-06 16:49:53 +00:00
|
|
|
(def __ nil)
|
2010-05-07 03:07:07 +00:00
|
|
|
(def ___ (fn [& args] args))
|
2010-01-24 03:28:43 +00:00
|
|
|
|
2010-02-06 16:49:53 +00:00
|
|
|
(defmacro meditations [& forms]
|
|
|
|
|
(let [pairs (partition 2 forms)]
|
|
|
|
|
`(do
|
2010-05-06 22:38:34 +00:00
|
|
|
~@(map
|
|
|
|
|
(fn [[doc# code#]]
|
|
|
|
|
`(when-not (is ~code# ~doc#)
|
|
|
|
|
(System/exit 0)))
|
|
|
|
|
pairs))))
|
2010-02-05 18:57:38 +00:00
|
|
|
|
2010-07-11 21:04:37 +00:00
|
|
|
(load "about_equalities"
|
|
|
|
|
"about_lists"
|
|
|
|
|
"about_vectors"
|
|
|
|
|
"about_sets"
|
|
|
|
|
"about_maps"
|
|
|
|
|
"about_functions"
|
|
|
|
|
"about_conditionals"
|
|
|
|
|
"about_higher_order_functions"
|
|
|
|
|
"about_runtime_polymorphism"
|
|
|
|
|
"about_sequence_comprehensions")
|
|
|
|
|
|
2010-05-06 22:38:34 +00:00
|
|
|
(println "You have achieved clojure enlightenment. Namaste.")
|