We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents 528789b + 4d1f3c2 commit 2eaeb95Copy full SHA for 2eaeb95
bin/primes
@@ -30,7 +30,7 @@ END {
30
chomp(my $start = @ARGV ? $ARGV[0] : <STDIN>);
31
my $end = $ARGV[1] || 2**32 - 1;
32
for ($start, $end) {
33
- s/^\s*\+?(\d{1,10}).*/$1/ || die "$0: $_: illegal numeric format\n";
+ s/\A\s*\+?(\d{1,10})\Z/$1/ || die "$0: $_: illegal numeric format\n";
34
$_ > 2**32 - 1 && die "$0: $_: Numerical result out of range\n";
35
}
36
die "$0: start value must be less than stop value\n" if ($end < $start);
0 commit comments