Function fmt_iter::repeat[][src]

pub fn repeat<Value: Display + Clone>(
    value: Value,
    times: usize
) -> FmtIter<impl Iterator<Item = Value> + ExactSizeIterator + Clone>

Notable traits for FmtIter<Inner>

impl<Inner> Iterator for FmtIter<Inner> where
    Inner: Iterator + Clone,
    Inner::Item: Display
type Item = Inner::Item;

Print a certain value multiple times.

Example:

let fmt_iter = repeat(123, 5);
assert_eq!(fmt_iter.to_string(), "123123123123123");