Function round

Source
pub fn round(x: f32) -> f32
Available on crate feature std only.
Expand description

Returns the nearest integer to x. If a value is half-way between two integers, round away from 0.0.

This function always returns the precise result.