Skip to content

Instantly share code, notes, and snippets.

@timmc
Created October 31, 2013 16:01
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save timmc/7252229 to your computer and use it in GitHub Desktop.
Save timmc/7252229 to your computer and use it in GitHub Desktop.
Ackermann in Swearjure
;; This is mechanically convertible to Swearjure:
(letfn [(A [m n]
(if (= m 0)
(inc n)
(if (= n 0)
(A (dec m) 1)
(A (dec m) (A m (dec n))))))]
(A 3 4))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment