[][src]Trait competitive_hpp::utils::math::MathUtils

pub trait MathUtils {
    fn log2_trunc(self) -> Self;
fn sqrt_floor(self) -> Self;
fn sqrt_ceil(self) -> Self; }

Required methods

fn log2_trunc(self) -> Self

Example:

use competitive_hpp::prelude::*;

assert_eq!(16.log2_trunc(), 4);
assert_eq!(10.log2_trunc(), 3);

fn sqrt_floor(self) -> Self

fn sqrt_ceil(self) -> Self

Loading content...

Implementations on Foreign Types

impl MathUtils for u64[src]

impl MathUtils for u32[src]

impl MathUtils for i64[src]

impl MathUtils for i32[src]

impl MathUtils for usize[src]

impl MathUtils for isize[src]

Loading content...

Implementors

Loading content...