Skip to main content

SquareRoot

Trait SquareRoot 

Source
pub trait SquareRoot {
    type Output;
}
Expand description

A type operator for taking the integer square root of Self.

The integer square root of n is the largest integer m such that n >= m*m. This definition is equivalent to truncating the real-valued square root: floor(real_sqrt(n)).

Required Associated Types§

Source

type Output

The result of the integer square root.

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§

Source§

impl<N> SquareRoot for N
where N: PrivateSquareRoot,

Source§

type Output = <N as PrivateSquareRoot>::Output