Function frunk::monoid::combine_n

source ·
pub fn combine_n<T>(o: &T, times: u32) -> Twhere
    T: Monoid + Semigroup + Clone,
Expand description

Return this combined with itself n times.

Examples

use frunk::monoid;

assert_eq!(monoid::combine_n(&Some(2), 4), Some(8));
Run