Created
June 1, 2016 14:40
-
-
Save japhb/6d263ce206208b20eb357581d187b40d to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env perl6 | |
sub MAIN($before, $after) { | |
my $pct = 100 * ($before - $after) / $before; | |
say abs($pct).fmt: "%9.2f%% {$pct < 0 ?? "more" !! "less"} time"; | |
say $pct < 0 ?? ($after / $before).fmt("%9.2f times slower") | |
!! ($before / $after).fmt("%9.2f times faster"); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment