How about...?
2, 3, -> *@x { first * %% none(@x), @x[*-1]..* } ... 100 # 2 3 5 7 11 13 17 19 23 ... 97
- → primes
Perl 6 | Perl 6 series operator | #14 |
2, 3, -> *@x { first * %% none(@x), @x[*-1]..* } ... 100 # 2 3 5 7 11 13 17 19 23 ... 97
Copyright © 2010 http://www.pmichaud.com/2010/pres/ |