Skip to main content
added 9 characters in body
Source Link
cliffroot
  • 1.1k
  • 6
  • 6

Clojure + Common Lisp, 2929 28 bytes

(print(if '()"trick""treat""trick"'treat))

Clojure version on ideone: https://ideone.com/8yvxxUhttps://ideone.com/3xIhpb

Common Lisp: https://ideone.com/IWsU6Xhttps://ideone.com/N3qzIW

In Common Lisp nil is the same as '() and thus '() evaluates to false whereas in Clojure empty list is not nil and thus is true. I hope its being not a full program but a snippet(?) is fine for the challenge.

Clojure + Common Lisp, 29 bytes

(print(if '()"trick""treat"))

Clojure version on ideone: https://ideone.com/8yvxxU

Common Lisp: https://ideone.com/IWsU6X

In Common Lisp nil is the same as '() and thus '() evaluates to false whereas in Clojure empty list is not nil and thus is true. I hope its being not a full program but a snippet(?) is fine for the challenge.

Clojure + Common Lisp, 29 28 bytes

(print(if '()"trick"'treat))

Clojure version on ideone: https://ideone.com/3xIhpb

Common Lisp: https://ideone.com/N3qzIW

In Common Lisp nil is the same as '() and thus '() evaluates to false whereas in Clojure empty list is not nil and thus is true. I hope its being not a full program but a snippet(?) is fine for the challenge.

Source Link
cliffroot
  • 1.1k
  • 6
  • 6

Clojure + Common Lisp, 29 bytes

(print(if '()"trick""treat"))

Clojure version on ideone: https://ideone.com/8yvxxU

Common Lisp: https://ideone.com/IWsU6X

In Common Lisp nil is the same as '() and thus '() evaluates to false whereas in Clojure empty list is not nil and thus is true. I hope its being not a full program but a snippet(?) is fine for the challenge.