Trait malachite_base::num::arithmetic::traits::FloorSqrtAssign

source ·
pub trait FloorSqrtAssign {
    // Required method
    fn floor_sqrt_assign(&mut self);
}
Expand description

Replaces a number with the floor of its square root.

Required Methods§

Implementations on Foreign Types§

source§

impl FloorSqrtAssign for i8

source§

fn floor_sqrt_assign(&mut self)

Replaces an integer with the floor of its square root.

$x \gets \lfloor\sqrt{x}\rfloor$.

§Worst-case complexity

Constant time and additional memory.

§Panics

Panics if self is negative.

§Examples

See here.

source§

impl FloorSqrtAssign for i16

source§

fn floor_sqrt_assign(&mut self)

Replaces an integer with the floor of its square root.

$x \gets \lfloor\sqrt{x}\rfloor$.

§Worst-case complexity

Constant time and additional memory.

§Panics

Panics if self is negative.

§Examples

See here.

source§

impl FloorSqrtAssign for i32

source§

fn floor_sqrt_assign(&mut self)

Replaces an integer with the floor of its square root.

$x \gets \lfloor\sqrt{x}\rfloor$.

§Worst-case complexity

Constant time and additional memory.

§Panics

Panics if self is negative.

§Examples

See here.

source§

impl FloorSqrtAssign for i64

source§

fn floor_sqrt_assign(&mut self)

Replaces an integer with the floor of its square root.

$x \gets \lfloor\sqrt{x}\rfloor$.

§Worst-case complexity

Constant time and additional memory.

§Panics

Panics if self is negative.

§Examples

See here.

source§

impl FloorSqrtAssign for i128

source§

fn floor_sqrt_assign(&mut self)

Replaces an integer with the floor of its square root.

$x \gets \lfloor\sqrt{x}\rfloor$.

§Worst-case complexity

Constant time and additional memory.

§Panics

Panics if self is negative.

§Examples

See here.

source§

impl FloorSqrtAssign for isize

source§

fn floor_sqrt_assign(&mut self)

Replaces an integer with the floor of its square root.

$x \gets \lfloor\sqrt{x}\rfloor$.

§Worst-case complexity

Constant time and additional memory.

§Panics

Panics if self is negative.

§Examples

See here.

source§

impl FloorSqrtAssign for u8

source§

fn floor_sqrt_assign(&mut self)

Replaces an integer with the floor of its square root.

$x \gets \lfloor\sqrt{x}\rfloor$.

§Worst-case complexity

Constant time and additional memory.

§Panics

Panics if self is negative.

§Examples

See here.

source§

impl FloorSqrtAssign for u16

source§

fn floor_sqrt_assign(&mut self)

Replaces an integer with the floor of its square root.

$x \gets \lfloor\sqrt{x}\rfloor$.

§Worst-case complexity

Constant time and additional memory.

§Panics

Panics if self is negative.

§Examples

See here.

source§

impl FloorSqrtAssign for u32

source§

fn floor_sqrt_assign(&mut self)

Replaces an integer with the floor of its square root.

$x \gets \lfloor\sqrt{x}\rfloor$.

§Worst-case complexity

Constant time and additional memory.

§Panics

Panics if self is negative.

§Examples

See here.

source§

impl FloorSqrtAssign for u64

source§

fn floor_sqrt_assign(&mut self)

Replaces an integer with the floor of its square root.

$x \gets \lfloor\sqrt{x}\rfloor$.

§Worst-case complexity

Constant time and additional memory.

§Panics

Panics if self is negative.

§Examples

See here.

source§

impl FloorSqrtAssign for u128

source§

fn floor_sqrt_assign(&mut self)

Replaces an integer with the floor of its square root.

$x \gets \lfloor\sqrt{x}\rfloor$.

§Worst-case complexity

Constant time and additional memory.

§Panics

Panics if self is negative.

§Examples

See here.

source§

impl FloorSqrtAssign for usize

source§

fn floor_sqrt_assign(&mut self)

Replaces an integer with the floor of its square root.

$x \gets \lfloor\sqrt{x}\rfloor$.

§Worst-case complexity

Constant time and additional memory.

§Panics

Panics if self is negative.

§Examples

See here.

Implementors§