aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMohammad Sajid Anwar <Mohammad.Anwar@yahoo.com>2025-10-23 16:19:58 +0100
committerGitHub <noreply@github.com>2025-10-23 16:19:58 +0100
commit481ca41d9ccaff8b7c66a1c2af953071870c8480 (patch)
treea009bc86b96596ace7e5d6dfa54b59f95fb3c15b
parentd3e6dbfcd4f23330c9fc0e39d106960c8436f91c (diff)
parentcbecf4d341431aceec2468d6a810554c07aa600b (diff)
downloadperlweeklychallenge-club-481ca41d9ccaff8b7c66a1c2af953071870c8480.tar.gz
perlweeklychallenge-club-481ca41d9ccaff8b7c66a1c2af953071870c8480.tar.bz2
perlweeklychallenge-club-481ca41d9ccaff8b7c66a1c2af953071870c8480.zip
Merge pull request #12908 from boblied/w344
Week 344 add blog reference
-rw-r--r--challenge-344/bob-lied/README.md2
-rw-r--r--challenge-344/bob-lied/blog.txt1
-rw-r--r--challenge-344/bob-lied/perl/ch-2.pl6
3 files changed, 5 insertions, 4 deletions
diff --git a/challenge-344/bob-lied/README.md b/challenge-344/bob-lied/README.md
index 090fa8d1ef..e2bb4bd5f2 100644
--- a/challenge-344/bob-lied/README.md
+++ b/challenge-344/bob-lied/README.md
@@ -2,4 +2,4 @@
## [PWC](https://perlweeklychallenge.org/blog/perl-weekly-challenge-344/)
## [GitHub](https://github.com/boblied/perlweeklychallenge-club/tree/master/challenge-344/bob-lied)
-[Blog](https://dev.to/boblied/)
+[Blog](https://dev.to/boblied/pwc-344-task-2-pick-up-the-pieces-3391)
diff --git a/challenge-344/bob-lied/blog.txt b/challenge-344/bob-lied/blog.txt
new file mode 100644
index 0000000000..59171e38e3
--- /dev/null
+++ b/challenge-344/bob-lied/blog.txt
@@ -0,0 +1 @@
+https://dev.to/boblied/pwc-344-task-2-pick-up-the-pieces-3391
diff --git a/challenge-344/bob-lied/perl/ch-2.pl b/challenge-344/bob-lied/perl/ch-2.pl
index d01505213a..80c4e73b84 100644
--- a/challenge-344/bob-lied/perl/ch-2.pl
+++ b/challenge-344/bob-lied/perl/ch-2.pl
@@ -83,11 +83,11 @@ sub canMake($source, $target)
return false;
}
-sub isPrefix($s, $t)
+sub isPrefix($p, $t)
{
- return false if @$s > @$t;
+ return false if @$p > @$t;
my $match = true;
- for my ($i, $n) ( indexed $s->@* )
+ for my ($i, $n) ( indexed $p->@* )
{
$match &&= ($n == $t->[$i]);
}