Skip to content

Instantly share code, notes, and snippets.

@Tux
Created February 13, 2015 12:12
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Tux/f75151ca740edc6e79e3 to your computer and use it in GitHub Desktop.
Save Tux/f75151ca740edc6e79e3 to your computer and use it in GitHub Desktop.
#!perl6
use v6;
use Slang::Tuxic;
my @ch = 1 .. 10;
for @ch -> $ch {
$ch == 5 and @ch.push (11..15);
$ch.say;
}
@ch.perl.say;
=>
1
2
3
4
5
6
7
8
9
10
Array.new(1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment