aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--challenge-030/Leoltron/README1
-rw-r--r--challenge-030/Leoltron/perl5/ch-1.pl11
2 files changed, 12 insertions, 0 deletions
diff --git a/challenge-030/Leoltron/README b/challenge-030/Leoltron/README
new file mode 100644
index 0000000000..28aeaf66ae
--- /dev/null
+++ b/challenge-030/Leoltron/README
@@ -0,0 +1 @@
+Solution by Leoltron
diff --git a/challenge-030/Leoltron/perl5/ch-1.pl b/challenge-030/Leoltron/perl5/ch-1.pl
new file mode 100644
index 0000000000..9b23635d2f
--- /dev/null
+++ b/challenge-030/Leoltron/perl5/ch-1.pl
@@ -0,0 +1,11 @@
+#!/usr/bin/perl
+
+use strict;
+use warnings;
+use 5.010;
+
+my $week_day = 2;
+for (2019 .. 2099) {
+ $week_day = ($week_day + ($_ % 4 == 0 ? 2 : 1)) % 7;
+ say $_ if $week_day == 0;
+}