Skip to content

Instantly share code, notes, and snippets.

@VienosNotes
Created August 24, 2011 17:00
Show Gist options
  • Save VienosNotes/1168537 to your computer and use it in GitHub Desktop.
Save VienosNotes/1168537 to your computer and use it in GitHub Desktop.
mD6 + nD10 in Perl6 (1)
use v6;
sub mD6 {
gather { take 6.rand.Int + 1 for 0..* }
}
sub nD10 {
gather { take 10.rand.Int for 0..* }
}
my ($m, $n) = @*ARGS;
say [+] mD6[1..$m], nD10[1..$n];
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment