aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--challenge-282/conor-hoekstra/ch-1.bqn11
-rw-r--r--challenge-282/conor-hoekstra/ch-2.bqn13
2 files changed, 24 insertions, 0 deletions
diff --git a/challenge-282/conor-hoekstra/ch-1.bqn b/challenge-282/conor-hoekstra/ch-1.bqn
new file mode 100644
index 0000000000..c8af7dc26d
--- /dev/null
+++ b/challenge-282/conor-hoekstra/ch-1.bqn
@@ -0,0 +1,11 @@
+# For up to date code:
+# https://github.com/codereport/bqn-code/blob/main/pwc/282-1.bqn
+
+⟨Group⟩ ⇐ •Import "../lib/fun.bqn"
+
+GoodInteger ← ⊑¯1∾˜·(3⊸=≠¨)⊸/Group
+
+# Tests
+•Show GoodInteger "12344456" # "444"
+•Show GoodInteger "1233334" # -1
+•Show GoodInteger "10020003" # "000"
diff --git a/challenge-282/conor-hoekstra/ch-2.bqn b/challenge-282/conor-hoekstra/ch-2.bqn
new file mode 100644
index 0000000000..9501d8a8c6
--- /dev/null
+++ b/challenge-282/conor-hoekstra/ch-2.bqn
@@ -0,0 +1,13 @@
+# For up to date code:
+# https://github.com/codereport/bqn-code/blob/main/pwc/282-2.bqn
+
+⟨Lower⟩ ⇐ •Import "../lib/string.bqn"
+⟨Differ⟩ ⇐ •Import "../lib/fun.bqn"
+
+Changes ← +´ · Differ Lower
+
+# Tests
+
+•Show Changes "pPeERrLl" # 3
+•Show Changes "rRr" # 0
+•Show Changes "GoO" # 1