commit 8554b324d4a0437c37ec37538ccfd6066775fc66 Author: setop Date: Thu Dec 1 22:45:38 2022 +0100 day 1 diff --git a/d01/part1.awk b/d01/part1.awk new file mode 100644 index 0000000..f838e55 --- /dev/null +++ b/d01/part1.awk @@ -0,0 +1,4 @@ +# awk -f part1.awk < input | sort -n | tail -n 1 +# awk -f part1.awk < input | sort -n | tail -n 3 | sum0 +NF == 0 { print a; a = 0 } +{ a+=$1 }