# Documentation for routine repeated

Documentation for routine repeated, assembled from the following types:

# class Any

From Any

## (Any) method repeated

Defined As:

method repeated(:, : --> Seq)

Treats the `Any`

as a 1-item list and uses `List.repeated`

on it.

say Any.repeated; # OUTPUT: «()»

# class List

From List

## (List) routine repeated

Defined as:

multi sub repeated(*, :, : --> Seq)multi method repeated(List: :, : --> Seq)

Returns a sequence of **repeated** values from the invocant/argument list. It takes the same parameters as `unique`

, but instead of passing through any elements when they're first seen, they're only passed through as soon as they're seen for the second time (or more).

Examples:

say <a a b b b c c>.repeated; # OUTPUT: «(a b b c)»say <a b b c c b a>.repeated; # OUTPUT: «(b c b a)»say <a A B b c b C>.repeated(:as()); # OUTPUT: «(A b b C)»my = , , ;say .repeated(:with(&[eqv])) # OUTPUT: «({a => 42})»