Skip to content

Instantly share code, notes, and snippets.

@kindlychung
Created May 8, 2015 14:29
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 kindlychung/f16aaa240e7fc63f00ab to your computer and use it in GitHub Desktop.
Save kindlychung/f16aaa240e7fc63f00ab to your computer and use it in GitHub Desktop.
(defmacro all [& args]
`(boolean (and ~@args)))
(defmacro any [& args]
`(boolean (or ~@args)))
(all 0 1 2 3 "" nil)
(any 0 1 2 3 "" nil)
(any (repeat 5))
;; returns true!!!!!
(all (repeat nil))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment