method skip-at-least
Documentation for method skip-at-least
assembled from the following types:
role Iterator
From Iterator
(Iterator) method skip-at-least
Defined as:
method skip-at-least(Iterator: , int --> Mu)
Should skip producing $to-skip
values. The return value should be truthy if the skip was successful and falsy if there were not enough values to be skipped:
my = <a b c>.iterator;say .skip-at-least(2); say .pull-one; say .skip-at-least(20);# OUTPUT: «1c0»
The Iterator role implements this method as a loop calling skip-one
and returning whether it returned a truthy value sufficient number of times.