(any-in? pred coll)
Returns true if (pred x) is logical true for any x in coll, else false.
Returns true if (pred x) is logical true for any x in coll, else false.
(average coll)
Gets the average of every element in coll
Gets the average of every element in coll
(average-by f coll)
Gets the average of (f x) for every x in coll
Gets the average of (f x) for every x in coll
(defnmem name & fndef)
Defines a memoized function Examples: (defnmem fibonacci [x] (if (or (= 0 x) (= 1 x)) 1 (+ (fibonacci (- x 1)) (fibonacci (- x 2)))))
Defines a memoized function Examples: (defnmem fibonacci [x] (if (or (= 0 x) (= 1 x)) 1 (+ (fibonacci (- x 1)) (fibonacci (- x 2)))))
(derefable? x)
Returns true if x is an instance of clojure.langIDeref
Returns true if x is an instance of clojure.langIDeref
(find-first pred coll)
Returns the first x in coll for which (pred x) returns true. returns nil if none is found
Returns the first x in coll for which (pred x) returns true. returns nil if none is found
(into-map coll)
(into-map kf coll)
(into-map kf vf coll)
Transforms coll into a hash-map by using (kf x) as the key and (vf x) as the value for each x in coll vf defaults to identity if not provided if only coll is provided, will assume coll is a list of pairs
Transforms coll into a hash-map by using (kf x) as the key and (vf x) as the value for each x in coll vf defaults to identity if not provided if only coll is provided, will assume coll is a list of pairs
(now)
Gets the time in milliseconds since unix epoch as a Long
Gets the time in milliseconds since unix epoch as a Long
(parse-int s)
Shortcut for Integer/parseInt to make it easier to pass around as an argument
Shortcut for Integer/parseInt to make it easier to pass around as an argument
(sum coll)
Gets the sum of every element in coll
Gets the sum of every element in coll
(sum-by f coll)
Gets the sum of (f x) for every x in coll
Gets the sum of (f x) for every x in coll
(update! m k f)
Like update, but for transients
Like update, but for transients
cljdoc is a website building & hosting documentation for Clojure/Script libraries
× close