** clojure code blocks and the lazies
:PROPERTIES:
:DATE: 2010-11-06
:END:
#+begin_src emacs-lisp :results silent
(defun org-babel-execute:clojure (body params)
(with-temp-buffer
(insert body)
(read
(slime-eval
`(swank:interactive-eval-region
,(buffer-substring-no-properties (point-min) (point-max)))))))
#+end_src
#+begin_src clojure
(map (fn [el] (list el (* el el)))(range 10))
#+end_src
#+name:
| 0 | 0 |
| 1 | 1 |
| 2 | 4 |
| 3 | 9 |
| 4 | 16 |
| 5 | 25 |
| 6 | 36 |
| 7 | 49 |
| 8 | 64 |
| 9 | 81 |