aboutsummaryrefslogtreecommitdiff
path: root/challenge-065
diff options
context:
space:
mode:
authorSimon Proctor <simon.proctor@zoopla.co.uk>2020-06-15 10:23:45 +0100
committerSimon Proctor <simon.proctor@zoopla.co.uk>2020-06-15 10:23:45 +0100
commit3fe990a60420be96a93c4d0dc80ea345fb418152 (patch)
treef44c90dc8f3b875b04894cf688b25597e77abac4 /challenge-065
parent5834ac4aec05ea3206c8a00ac56b90d2f117812f (diff)
downloadperlweeklychallenge-club-3fe990a60420be96a93c4d0dc80ea345fb418152.tar.gz
perlweeklychallenge-club-3fe990a60420be96a93c4d0dc80ea345fb418152.tar.bz2
perlweeklychallenge-club-3fe990a60420be96a93c4d0dc80ea345fb418152.zip
Don't need the gathers here
Diffstat (limited to 'challenge-065')
-rw-r--r--challenge-065/simon-proctor/raku/ch-1.p64
1 files changed, 2 insertions, 2 deletions
diff --git a/challenge-065/simon-proctor/raku/ch-1.p6 b/challenge-065/simon-proctor/raku/ch-1.p6
index 9843b1459e..dd019f5930 100644
--- a/challenge-065/simon-proctor/raku/ch-1.p6
+++ b/challenge-065/simon-proctor/raku/ch-1.p6
@@ -18,9 +18,9 @@ multi sub MAIN (
.say for calculate-sums( $n, $s, 1 ).grep( { defined $_ } );
}
-multi sub calculate-sums( UInt $n, UInt $s where { $n * 9 < $s }, $ ) { gather take Nil }
+multi sub calculate-sums( UInt $n, UInt $s where { $n * 9 < $s }, $ ) {}
-multi sub calculate-sums( UInt $n, 0, $ ) { gather take 0 x $n }
+multi sub calculate-sums( UInt $n, 0, $ ) { 0 x $n }
multi sub calculate-sums( UInt $n, UInt $s, $start = 0 ) {
my $end = $s > 9 ?? 9 !! $s;