Skip to content

Commit

Permalink
Adds example to deepmap, refs #1720
Browse files Browse the repository at this point in the history
  • Loading branch information
JJ committed Jul 23, 2019
1 parent c97dda0 commit 7194750
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions doc/Type/Any.pod6
Expand Up @@ -201,6 +201,12 @@ L<deepmap|/routine/deepmap> will descend recursively into the sublist.
say [[1,2,3],[[4,5],6,7]].deepmap(* + 1);
# OUTPUT: «[[2 3 4] [[5 6] 7 8]]␤»
In the case of C<Associative>s, it will be applied to its values:
=for code
{ what => "is", this => "thing", a => <real list> }.deepmap( *.flip ).say
# OUTPUT: «{a => (laer tsil), this => gniht, what => si}␤»
=head2 method duckmap
Defined as:
Expand Down

0 comments on commit 7194750

Please sign in to comment.