From 13440b6d1d67118b56afa6e2036bba45ace43878 Mon Sep 17 00:00:00 2001 From: Thomas Voss Date: Thu, 12 Dec 2024 19:38:53 +0100 Subject: Fix formatting --- 2024/12/puzzles.lisp | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) (limited to '2024/12') diff --git a/2024/12/puzzles.lisp b/2024/12/puzzles.lisp index 3a02033..a07575e 100644 --- a/2024/12/puzzles.lisp +++ b/2024/12/puzzles.lisp @@ -3,8 +3,8 @@ (defparameter *seen* (make-hash-table :test #'equal)) -(defun read-grid (filename) - (with-open-file (stream filename) +(defconstant +farm+ + (with-open-file (stream "input") (let ((lines (loop for line = (read-line stream nil) while line collect (coerce line 'array)))) @@ -12,9 +12,6 @@ (length (first lines))) :initial-contents lines)))) -(defconstant +farm+ - (read-grid "input")) - (defun main () (loop with dimensions = (array-dimensions +farm+) for i from 0 below (first dimensions) -- cgit v1.2.3