Factorial: Difference between revisions

m
Change a "Perl 6" reference to "Raku"
(added RASEL)
m (Change a "Perl 6" reference to "Raku")
Line 7,263:
 
=== via Memoized Constant Sequence ===
This approach is much more efficient for repeated use, since it automatically caches. <tt>[\*]</tt> is the so-called triangular version of [*]. It returns the intermediate results as a list. Note that Perl 6Raku allows you to define constants lazily, which is rather helpful when your constant is of infinite size...
{{works with|Rakudo|2015.12}}
<lang perl6>constant fact = 1, |[\*] 1..*;