book
book copied to clipboard
chap4, 4.6 unpacking code sample failed to work
# same thing:
sub first-is-largest(@a) {
my :($first, *@rest) := \(|@a);
~~~~~~~~~~This line is not working in rakudo
return $first >= all(@rest);
}
(17:06:38) woosley: rakudo: @a = 2, 3, 4; my :($f, *$o) := (|@a); say $f.perl (17:06:41) p6eval: rakudo 549d2a: OUTPUT«===SORRY!===Malformed my at line 22, near ":($f, $o) "»