From 9ef10406c067d0a0532d609212a94519af402b87 Mon Sep 17 00:00:00 2001 From: Marvin Borner Date: Tue, 7 Mar 2023 00:19:48 +0100 Subject: Added a few advent of code solutions --- samples/aoc/2021/01/solve.bruijn | 14 ++++++++++++++ 1 file changed, 14 insertions(+) create mode 100644 samples/aoc/2021/01/solve.bruijn (limited to 'samples/aoc/2021/01/solve.bruijn') diff --git a/samples/aoc/2021/01/solve.bruijn b/samples/aoc/2021/01/solve.bruijn new file mode 100644 index 0000000..d48acff --- /dev/null +++ b/samples/aoc/2021/01/solve.bruijn @@ -0,0 +1,14 @@ +:import std/Math . +:import std/String . + +part1 [{ [[(1 (lines 0) + parts [∑(part1 0) : ∑(part2 0)] + +# equivalent alternative using std/Pair P +# part1 [length (filter (P.uncurry …