, - , , , boolean? instance?. varargs:
(defn bools?
[& xs]
(every? (partial instance? Boolean) xs))
:
>> (bools? true) => true
>> (bools? true false) => true
>> (bools? true nil) => false
I never had to do this, since I had just dealt with the values and the fact that everything in clojure is “true”, with the exception of false or nil.
source
share