day 4
This commit is contained in:
parent
06ba0f14ac
commit
a89bf6e2c0
3 changed files with 188 additions and 1 deletions
44
day4/default.nix
Normal file
44
day4/default.nix
Normal file
|
@ -0,0 +1,44 @@
|
|||
{ lib, utils, ... }:
|
||||
with lib;
|
||||
with builtins;
|
||||
with utils;
|
||||
let
|
||||
lines = readLines ./input;
|
||||
grid = map stringToCharacters lines;
|
||||
cols = map concatStrings (transpose grid);
|
||||
construct_diags' = matrix:
|
||||
map (filter (invert isNull)) (transpose (map (i:
|
||||
(genList (const null) i) ++ (elemAt matrix i)
|
||||
++ (genList (const null) ((length (head matrix)) - i - 1)))
|
||||
(listRange matrix)));
|
||||
construct_diags = matrix: construct_diags' (map reverseList matrix);
|
||||
diags_1 = map concatStrings (construct_diags grid);
|
||||
diags_2 = map concatStrings (construct_diags' (grid));
|
||||
in {
|
||||
part1 =
|
||||
listSumWith (s: (length (matchAll "XMAS" s)) + (length (matchAll "SAMX" s)))
|
||||
(lines ++ cols ++ diags_1 ++ diags_2);
|
||||
part2 = listSumWith (li:
|
||||
let
|
||||
l = elemAt grid li;
|
||||
t = elemAt grid (li - 1);
|
||||
b = elemAt grid (li + 1);
|
||||
in count (ri:
|
||||
let
|
||||
tl = elemAt t (ri - 1);
|
||||
tr = elemAt t (ri + 1);
|
||||
mm = elemAt l ri;
|
||||
bl = elemAt b (ri - 1);
|
||||
br = elemAt b (ri + 1);
|
||||
|
||||
tests = map concatStrings [
|
||||
[ tl mm br ]
|
||||
[ tr mm bl ]
|
||||
[ br mm tl ]
|
||||
[ bl mm tr ]
|
||||
];
|
||||
|
||||
# Idea: each X-MAS contains exactly 2 matching MAS centered around the A
|
||||
in (count (eq "MAS") tests) == 2) (range 1 ((length l) - 2)))
|
||||
(range 1 ((length grid) - 2));
|
||||
}
|
140
day4/input
Normal file
140
day4/input
Normal file
|
@ -0,0 +1,140 @@
|
|||
SXMSMMXMASMSSSSXAMXMXAMXXAAXMAMSAMMXMAMXSAMXMXMMMMSMMXMXMASMM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|
|||
abs = i: if i >= 0 then i else i * -1;
|
||||
delta = x: y: abs (x - y);
|
||||
listSum = foldl' add 0;
|
||||
listSumWith = f: l: foldl' add 0 (map f l);
|
||||
deleteAt = l: i: (take i l) ++ (drop (i + 1) l);
|
||||
eq = x: y: x == y;
|
||||
greaterThan = x: y: x > y;
|
||||
listRange = l: range 0 (length l);
|
||||
listRange = l: range 0 ((length l) - 1);
|
||||
transpose = l: map (i: map ((flip elemAt) i) l) (listRange (head l));
|
||||
invert = f: x: !(f x);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue