aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--challenge-112/colin-crain/perl/ch-1.pl245
-rw-r--r--challenge-114/aaronreidsmith/blog.txt1
-rw-r--r--challenge-114/aaronreidsmith/raku/ch-1.raku24
-rw-r--r--challenge-114/aaronreidsmith/raku/ch-2.raku30
-rw-r--r--challenge-114/abigail/README.md70
-rw-r--r--challenge-114/abigail/awk/ch-1.awk44
-rw-r--r--challenge-114/abigail/awk/ch-2.gawk47
-rw-r--r--challenge-114/abigail/bash/ch-1.sh62
-rw-r--r--challenge-114/abigail/bash/ch-2.sh39
-rw-r--r--challenge-114/abigail/blog.txt1
-rw-r--r--challenge-114/abigail/blog1.txt1
-rw-r--r--challenge-114/abigail/c/ch-1.c97
-rw-r--r--challenge-114/abigail/c/ch-2.c69
-rw-r--r--challenge-114/abigail/perl/ch-1.pl50
-rw-r--r--challenge-114/abigail/perl/ch-2.pl27
-rw-r--r--challenge-114/abigail/t/ctest.ini11
-rw-r--r--challenge-114/abigail/t/input-1-12
-rw-r--r--challenge-114/abigail/t/input-1-26
-rw-r--r--challenge-114/abigail/t/input-1-310
-rw-r--r--challenge-114/abigail/t/input-2-12
-rw-r--r--challenge-114/abigail/t/input-2-21024
-rw-r--r--challenge-114/abigail/t/output-1-1.exp2
-rw-r--r--challenge-114/abigail/t/output-1-2.exp6
-rw-r--r--challenge-114/abigail/t/output-1-3.exp10
-rw-r--r--challenge-114/abigail/t/output-2-1.exp2
-rw-r--r--challenge-114/abigail/t/output-2-2.exp1024
-rw-r--r--challenge-114/adam-russell/blog.txt1
-rw-r--r--challenge-114/adam-russell/blog1.txt1
-rw-r--r--challenge-114/adam-russell/perl/ch-1.pl23
-rw-r--r--challenge-114/adam-russell/perl/ch-2.pl36
-rw-r--r--challenge-114/adam-russell/prolog/ch-1.p18
-rw-r--r--challenge-114/adam-russell/prolog/ch-2.p26
-rw-r--r--challenge-114/arne-sommer/blog.txt1
-rw-r--r--challenge-114/arne-sommer/misc/tree1.svg119
-rw-r--r--challenge-114/arne-sommer/misc/tree2.svg109
-rw-r--r--challenge-114/arne-sommer/misc/tree3.svg119
-rwxr-xr-xchallenge-114/arne-sommer/perl/ch-1.pl25
-rwxr-xr-xchallenge-114/arne-sommer/perl/ch-2.pl34
-rwxr-xr-xchallenge-114/arne-sommer/perl/higher-integer-set-bits-perl34
-rwxr-xr-xchallenge-114/arne-sommer/perl/next-palindrome-number-perl25
-rwxr-xr-xchallenge-114/arne-sommer/raku/ch-1.raku14
-rwxr-xr-xchallenge-114/arne-sommer/raku/ch-2.raku22
-rwxr-xr-xchallenge-114/arne-sommer/raku/higher-integer-set-bits22
-rwxr-xr-xchallenge-114/arne-sommer/raku/next-palindrome-number14
-rw-r--r--challenge-114/athanasius/perl/ch-1.pl160
-rw-r--r--challenge-114/athanasius/perl/ch-2.pl201
-rw-r--r--challenge-114/athanasius/raku/ch-1.raku139
-rw-r--r--challenge-114/athanasius/raku/ch-2.raku183
-rw-r--r--challenge-114/cheok-yin-fung/perl/ch-1.pl61
-rw-r--r--challenge-114/cheok-yin-fung/perl/ch-2.pl66
-rw-r--r--challenge-114/christian-jaeger/blog.txt1
-rw-r--r--challenge-114/christian-jaeger/haskell/Makefile2
-rwxr-xr-xchallenge-114/christian-jaeger/perl/ch-1.pl212
-rw-r--r--challenge-114/colin-crain/blog.txt1
-rw-r--r--challenge-114/colin-crain/perl/ch-1.pl116
-rw-r--r--challenge-114/colin-crain/perl/ch-2.pl182
-rw-r--r--challenge-114/colin-crain/raku/ch-1.raku38
-rw-r--r--challenge-114/colin-crain/raku/ch-2.raku67
-rw-r--r--challenge-114/duncan-c-white/README62
-rw-r--r--challenge-114/duncan-c-white/perl/bintree.eg8
-rwxr-xr-xchallenge-114/duncan-c-white/perl/ch-1.pl49
-rwxr-xr-xchallenge-114/duncan-c-white/perl/ch-2.pl66
-rw-r--r--challenge-114/james-smith/README.md417
-rw-r--r--challenge-114/james-smith/blog.txt1
-rw-r--r--challenge-114/james-smith/perl/ch-1.pl69
-rw-r--r--challenge-114/james-smith/perl/ch-2.pl128
-rwxr-xr-xchallenge-114/jo-37/perl/ch-1.pl95
-rwxr-xr-xchallenge-114/jo-37/perl/ch-2.pl107
-rw-r--r--challenge-114/lance-wicks/perl/ch-1.pl12
-rw-r--r--challenge-114/lance-wicks/perl/lib/Palindrome.pm13
-rw-r--r--challenge-114/lance-wicks/perl/t/00-palindrome.t12
-rw-r--r--challenge-114/laurent-rosenfeld/blog.txt1
-rw-r--r--challenge-114/laurent-rosenfeld/perl/ch-1.pl9
-rw-r--r--challenge-114/laurent-rosenfeld/perl/ch-2.pl16
-rw-r--r--challenge-114/laurent-rosenfeld/python/ch-1.py8
-rw-r--r--challenge-114/laurent-rosenfeld/raku/ch-1.raku8
-rw-r--r--challenge-114/laurent-rosenfeld/raku/ch-2.raku13
-rw-r--r--challenge-114/laurent-rosenfeld/scala/ch-1.scala11
-rw-r--r--challenge-114/laurent-rosenfeld/scala/ch-2.scala21
-rw-r--r--challenge-114/mark-anderson/raku/ch-1.raku8
-rw-r--r--challenge-114/mark-anderson/raku/ch-2.raku10
-rw-r--r--challenge-114/mimosinnet/raku/ch-1.raku25
-rw-r--r--challenge-114/mimosinnet/raku/ch-2.raku25
-rw-r--r--challenge-114/pete-houston/perl/ch-1.pl48
-rw-r--r--challenge-114/pete-houston/perl/ch-2.pl83
-rw-r--r--challenge-114/polettix/blog.txt1
-rw-r--r--challenge-114/polettix/blog1.txt1
-rw-r--r--challenge-114/polettix/perl/ch-1.pl29
-rw-r--r--challenge-114/polettix/perl/ch-2.pl17
-rw-r--r--challenge-114/polettix/raku/ch-1.raku28
-rw-r--r--challenge-114/polettix/raku/ch-2.raku16
-rw-r--r--challenge-114/richard-park/apl/ch-1.aplf1
-rw-r--r--challenge-114/richard-park/apl/ch-2.aplf7
-rw-r--r--challenge-114/roger-bell-west/blog.txt1
-rw-r--r--challenge-114/tyler-wardhaugh/clojure/src/tw/weekly/c114/core.clj12
-rw-r--r--challenge-114/tyler-wardhaugh/clojure/src/tw/weekly/c114/t1.clj21
-rw-r--r--challenge-114/tyler-wardhaugh/clojure/src/tw/weekly/c114/t2.clj21
-rw-r--r--challenge-114/tyler-wardhaugh/clojure/test/tw/weekly/c114_test.clj14
-rw-r--r--challenge-114/wambash/raku/ch-1.raku22
-rw-r--r--challenge-114/wambash/raku/ch-2.raku26
-rw-r--r--challenge-114/wanderdoc/perl/ch-1.pl99
-rw-r--r--stats/pwc-current.json474
-rw-r--r--stats/pwc-language-breakdown-summary.json62
-rw-r--r--stats/pwc-language-breakdown.json1564
-rw-r--r--stats/pwc-leaders.json844
-rw-r--r--stats/pwc-summary-1-30.json74
-rw-r--r--stats/pwc-summary-121-150.json44
-rw-r--r--stats/pwc-summary-151-180.json56
-rw-r--r--stats/pwc-summary-181-210.json104
-rw-r--r--stats/pwc-summary-211-240.json70
-rw-r--r--stats/pwc-summary-31-60.json122
-rw-r--r--stats/pwc-summary-61-90.json58
-rw-r--r--stats/pwc-summary-91-120.json110
-rw-r--r--stats/pwc-summary.json116
114 files changed, 7829 insertions, 2488 deletions
diff --git a/challenge-112/colin-crain/perl/ch-1.pl b/challenge-112/colin-crain/perl/ch-1.pl
index 3a638cea0f..ff7a309d49 100644
--- a/challenge-112/colin-crain/perl/ch-1.pl
+++ b/challenge-112/colin-crain/perl/ch-1.pl
@@ -1,107 +1,138 @@
-#!/Users/colincrain/perl5/perlbrew/perls/perl-5.32.0/bin/perl
-#
-# where-am-i-where-are-my-friends.pl
-#
-# Canonical Path
-# Submitted by: Mohammad S Anwar
-# You are given a string path, starting with a slash ‘/'.
-#
-# Write a script to convert the given absolute path to the simplified
-# canonical path.
-#
-# In a Unix-style file system:
-#
-# - A period '.' refers to the current directory
-# - A double period '..' refers to the directory up a level
-# - Multiple consecutive slashes ('//') are treated as a single slash '/'
-# The canonical path format:
-#
-# - The path starts with a single slash '/'.
-# - Any two directories are separated by a single slash '/'.
-# - The path does not end with a trailing '/'.
-# - The path only contains the directories on the path from the root
-# directory to the target file or directory
-#
-# Example
-# Input: "/a/"
-# Output: "/a"
-#
-# Input: "/a/b//c/"
-# Output: "/a/b/c"
-#
-# Input: "/a/b/c/../.."
-# Output: "/a"
-#
-# method
-# converting to a canonical path form is not quite as simple as
-# restructuring dot file notaion into real directories and
-# normalizing superfluous chaff such as '//', because a canonical
-# path is always an absolute path and the relative path given may
-# not be.
-#
-# Fortunately for us today we are defined as having been given an
-# absolute path, sidestepping that mess.
-#
-# However a canonical path also resolves soft links, which remains a
-# difficulty, as Perl is not a shell. There are ways involving a module
-# to address this, but I'm going to assume this edge case is outside
-# the scope of the problem.
-#
-#
-# © 2021 colin crain
-## ## ## ## ## ## ## ## ## ## ## ## ## ## ## ## ## ## ## ##
-
-
-
-use warnings;
-use strict;
-use feature ":5.26";
-use feature qw(signatures);
-no warnings 'experimental::signatures';
-
-use Cwd qw( abs_path );
-
-
-
-sub canonical ($path) {
- $path =~ s{/\.?/}{/}g;
- $path =~ s{/$}{};
-
- my @parts = split '/', $path;
- my $pos = 0;
- while (++$pos < @parts) {
- if ($parts[$pos] eq '..') {
- splice @parts, $pos-1, 2;
- $pos -= 2;
- }
- }
- join '/', @parts;
-}
-
-# this will resolve relative paths, and soft links, from the cwd, which doesn't
-# really solve that problem in a general way. We need to `chdir` over to
-# the place in question, which would need to both exist and have the right permissions.
-# The whole thing is a bit of a mess, really, and I don't think that's what Mohammad is
-# asking of us.
-
-sub canonical_softlinks ($path) {
- chdir $path;
- return abs_path( $path );
-}
-
-## resolving the link from d -> e
-## yields /Users/colincrain/a/b/c/e
-
-my $path = '../../a/b/c/f/../d';
-say canonical_softlinks( $path );
-
-
-
-use Test::More;
-
-is canonical("/a/"), "/a" , 'ex-1';
-is canonical("/a/b//c/"), "/a/b/c" , 'ex-2';
-is canonical("/a/b/c/../.."), "/a" , 'ex-3';
-
-done_testing();
-
+#!/Users/colincrain/perl5/perlbrew/perls/perl-5.32.0/bin/perl
+#
+# PWC 112 - TASK 1
+#
+# where-am-i-where-are-my-friends.pl
+#
+# Canonical Path
+# Submitted by: Mohammad S Anwar
+# You are given a string path, starting with a slash ‘/'.
+#
+# Write a script to convert the given absolute path to the simplified
+# canonical path.
+#
+# In a Unix-style file system:
+#
+# - A period '.' refers to the current directory
+# - A double period '..' refers to the directory up a level
+# - Multiple consecutive slashes ('//') are treated as a single slash '/'
+# The canonical path format:
+#
+# - The path starts with a single slash '/'.
+# - Any two directories are separated by a single slash '/'.
+# - The path does not end with a trailing '/'.
+# - The path only contains the directories on the path from the root
+# directory to the target file or directory
+#
+# Example
+# Input: "/a/"
+#