aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--challenge-090/paulo-custodio/perl/ch-2.pl2
1 files changed, 1 insertions, 1 deletions
diff --git a/challenge-090/paulo-custodio/perl/ch-2.pl b/challenge-090/paulo-custodio/perl/ch-2.pl
index b539b8dc6a..0937ccc6b5 100644
--- a/challenge-090/paulo-custodio/perl/ch-2.pl
+++ b/challenge-090/paulo-custodio/perl/ch-2.pl
@@ -13,7 +13,7 @@ my($a, $b) = @ARGV;
my $mul = 0;
while (1) {
$mul += $b if ($a & 1) != 0;
- last if $a == 1;
+ last if $a <= 1;
$a >>= 1; $b <<= 1;
}
print $mul, "\n";