diff options
Diffstat (limited to 'users/sterni/exercises/aoc/2022/02')
-rw-r--r-- | users/sterni/exercises/aoc/2022/02/2.bqn | 7 | ||||
-rw-r--r-- | users/sterni/exercises/aoc/2022/02/2.k | 1 |
2 files changed, 8 insertions, 0 deletions
diff --git a/users/sterni/exercises/aoc/2022/02/2.bqn b/users/sterni/exercises/aoc/2022/02/2.bqn new file mode 100644 index 000000000000..65e3c817bbd2 --- /dev/null +++ b/users/sterni/exercises/aoc/2022/02/2.bqn @@ -0,0 +1,7 @@ +lib ← •Import •path∾"/../../lib.bqn" +i ← 3|"ABCXYZ"⊸⊐¨ ' ' ⊑¨∘lib.SplitOn¨ •FLines •path∾"/input" +S1 ← {1+𝕩+3×3|1+𝕩-𝕨} +S2 ← {𝕨 S1 3|𝕨+𝕩-1} + +•Out "day02.1: "∾•Fmt +´S1´¨i +•Out "day02.2: "∾•Fmt +´S2´¨i diff --git a/users/sterni/exercises/aoc/2022/02/2.k b/users/sterni/exercises/aoc/2022/02/2.k new file mode 100644 index 000000000000..9b6d10058d77 --- /dev/null +++ b/users/sterni/exercises/aoc/2022/02/2.k @@ -0,0 +1 @@ ++/{{y+1+3*3!1+y-x}[x]'y,3!x+y-1}.'3!"ABCXYZ"?(0:"input")_'1 |