Special variables: Difference between revisions
Content added Content deleted
(Adds Clojure solution) |
|||
Line 414: | Line 414: | ||
=={{header|Clojure}}== |
=={{header|Clojure}}== |
||
The following snippet prints a list of the special variables defined in clojure.core, in *earmuff* form: |
The following snippet prints a list of the special variables defined in clojure.core, in *earmuff* form. For further information, consult the [http://clojuredocs.org/quickref/shortdesc/Clojure%20Core documentation]. |
||
<lang clojure> |
<lang clojure> |
||
(apply str (interpose " " (sort (filter #(.startsWith % "*") (map str (keys (ns-publics 'clojure.core))))))) |
(apply str (interpose " " (sort (filter #(.startsWith % "*") (map str (keys (ns-publics 'clojure.core))))))) |