aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCY Fung <fungcheokyin@gmail.com>2022-06-07 21:17:33 +0800
committerCY Fung <fungcheokyin@gmail.com>2022-06-07 21:17:33 +0800
commit3cc61075c2564e35c4826d6431312e2b0dcf2179 (patch)
tree3c0f4289cc2ac75f5c19cb88c8f878a9df4a2ec9
parent2f661f978631af53d9cb473cdef818b8833ca0e9 (diff)
downloadperlweeklychallenge-club-3cc61075c2564e35c4826d6431312e2b0dcf2179.tar.gz
perlweeklychallenge-club-3cc61075c2564e35c4826d6431312e2b0dcf2179.tar.bz2
perlweeklychallenge-club-3cc61075c2564e35c4826d6431312e2b0dcf2179.zip
to be improved within this week
-rw-r--r--challenge-168/cheok-yin-fung/perl/ch-2.pl4
1 files changed, 3 insertions, 1 deletions
diff --git a/challenge-168/cheok-yin-fung/perl/ch-2.pl b/challenge-168/cheok-yin-fung/perl/ch-2.pl
index 0518d1dbcd..3289846cfe 100644
--- a/challenge-168/cheok-yin-fung/perl/ch-2.pl
+++ b/challenge-168/cheok-yin-fung/perl/ch-2.pl
@@ -1,3 +1,5 @@
+# CAN BE IMPROVED
+
#!/usr/bin/perl
# The Weekly Challenge 168
# Task 2 Home Prime
@@ -39,7 +41,7 @@ sub my_hp {
$num /= $p;
}
else {
- $p = next_prime($p);
+ $p = next_prime($p); # CAN BE IMPROVED
}
} while ($num != 1);
my $nxt = (reduce { $a . $b } @factors);