macro | since v0.0-927 | clojure.core/dotimes | Edit |
(dotimes bindings & body)
Repeatedly executes body
(presumably for side-effects) with name
bound to
integers from 0 through n
-1.
bindings => name n Repeatedly executes body (presumably for side-effects) with name bound to integers from 0 through n-1.
(core/defmacro dotimes
[bindings & body]
(core/let [i (first bindings)
n (second bindings)]
`(let [n# ~n]
(loop [~i 0]
(when (< ~i n#)
~@body
(recur (inc ~i)))))))