ClojureDocs

Nav

Namespaces

Clojure/Conj 2026 — Charlotte, NC — Sept 30 - Oct 2 Learn More & Get Tickets →

rint

clojure.math

Available since 1.11 (source)
  • (rint a)
Returns the double closest to a and equal to a mathematical integer.
If two values are equally close, return the even one.
If a is ##NaN or ##Inf or ##-Inf or zero => a
See: https://docs.oracle.com/javase/8/docs/api/java/lang/Math.html#rint-double-