round
Rounds the given value x towards the closest integer with ties rounded towards even integer.
Special cases:
round(x)
isx
wherex
isNaN
or+Inf
or-Inf
or already a mathematical integer.
Try the revamped Kotlin docs design →
Try the revamped Kotlin docs design!
Rounds the given value x towards the closest integer with ties rounded towards even integer.
Special cases:
round(x)
is x
where x
is NaN
or +Inf
or -Inf
or already a mathematical integer.