aboutsummaryrefslogtreecommitdiff
path: root/challenge-018
diff options
context:
space:
mode:
authorAdam Russell <adam.russell@optum.com>2019-07-28 02:32:28 -0400
committerAdam Russell <adam.russell@optum.com>2019-07-28 02:32:28 -0400
commit5da3fb19768f5a4d909e18921e1fb057dfb97d7c (patch)
tree3c30532bdab0b244896c961b855b44ce44c10182 /challenge-018
parentf79ded77acf482b07c327bf1408620d390832842 (diff)
downloadperlweeklychallenge-club-5da3fb19768f5a4d909e18921e1fb057dfb97d7c.tar.gz
perlweeklychallenge-club-5da3fb19768f5a4d909e18921e1fb057dfb97d7c.tar.bz2
perlweeklychallenge-club-5da3fb19768f5a4d909e18921e1fb057dfb97d7c.zip
solutions for challenge 018
Diffstat (limited to 'challenge-018')
-rw-r--r--challenge-018/adam-russell/blog.txt1
-rw-r--r--challenge-018/adam-russell/perl5/SuffixArray.pm1
-rw-r--r--challenge-018/adam-russell/perl5/ch-2.pl5
3 files changed, 4 insertions, 3 deletions
diff --git a/challenge-018/adam-russell/blog.txt b/challenge-018/adam-russell/blog.txt
index e69de29bb2..4a5c19a082 100644
--- a/challenge-018/adam-russell/blog.txt
+++ b/challenge-018/adam-russell/blog.txt
@@ -0,0 +1 @@
+https://adamcrussell.livejournal.com/6109.html
diff --git a/challenge-018/adam-russell/perl5/SuffixArray.pm b/challenge-018/adam-russell/perl5/SuffixArray.pm
index b40df310c3..c480d4517d 100644
--- a/challenge-018/adam-russell/perl5/SuffixArray.pm
+++ b/challenge-018/adam-russell/perl5/SuffixArray.pm
@@ -1,7 +1,6 @@
use strict;
use warnings;
package SuffixArray{
-use Data::Dump q/pp/;
use boolean;
use Class::Struct;
struct(
diff --git a/challenge-018/adam-russell/perl5/ch-2.pl b/challenge-018/adam-russell/perl5/ch-2.pl
index 649b92db19..b67cab8bf0 100644
--- a/challenge-018/adam-russell/perl5/ch-2.pl
+++ b/challenge-018/adam-russell/perl5/ch-2.pl
@@ -8,6 +8,7 @@ $pq->insert_with_priority(5, "drink water");
$pq->insert_with_priority(1, "eat pizza");
$pq->insert_with_priority(2, "work on perl weekly challenge");
$pq->insert_with_priority(6, "clean dishes");
-for (0..6){
- printf("%s\n", $pq->pull_highest_priority_element());
+for(0 .. 6){
+ my $data = $pq->pull_highest_priority_element();
+ printf("$data\n");
}