Skip to content

Instantly share code, notes, and snippets.

@colomon
Forked from TimToady/modmap
Last active December 17, 2015 04:18
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 colomon/5549331 to your computer and use it in GitHub Desktop.
Save colomon/5549331 to your computer and use it in GitHub Desktop.
sub modmap (Int $x is copy, @rads) {
gather {
while $x and @rads {
my $rad = @rads.shift;
take $x % $rad;
$x div= $rad;
}
take $x if $x;
}
}
say modmap 2804985923338703271682399481743033703427656749129565173066, 256 xx *;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment