Skip to content

iter::repeat

repeat(item)
repeat(item, n: Integer)

ParameterTypeDescription
item*The object to repeat
(optional) nIntegerThe amount of times it should be repeated

Returns

(Generator) A list containing n instances of the given item.