advent-of-code-2023

My solutions to AoC 2023
git clone git://git.entf.net/advent-of-code-2023
Log | Files | Refs

commit 99af642db393d53c811ac5bcae0016c052dd3287
parent b1251b8a6682777e96178b3927705f9883028715
Author: Lukas Henkel <lh@entf.net>
Date:   Sat,  2 Dec 2023 19:18:35 +0100

Much simpler

Diffstat:
Msrc/day-2.lisp | 6+-----
1 file changed, 1 insertion(+), 5 deletions(-)

diff --git a/src/day-2.lisp b/src/day-2.lisp @@ -44,11 +44,7 @@ (declaim (ftype (function (list) fixnum) game-power)) (defun game-power (sets) - (apply #'* - (apply #'mapcar - (cons (lambda (&rest values) - (apply #'max values)) - sets)))) + (apply #'* (apply (curry #'mapcar #'max) sets))) (defun day-2 (input) (loop for line = (read-line input nil)