advent-of-code-2024

My solutions to AoC 2024
Log | Files | Refs

day-5.lisp (468B)


      1 (defpackage #:aoc-test/day-5
      2   (:use #:cl #:lisp-unit2)
      3   (:import-from #:aoc/day-5))
      4 (in-package #:aoc-test/day-5)
      5 
      6 (define-test test-day-5
      7     ()
      8   (multiple-value-bind (task-1 task-2)
      9       (aoc:run-day 5 "47|53
     10 97|13
     11 97|61
     12 97|47
     13 75|29
     14 61|13
     15 75|53
     16 29|13
     17 97|29
     18 53|29
     19 61|53
     20 97|53
     21 61|29
     22 47|13
     23 75|47
     24 97|75
     25 47|61
     26 75|61
     27 47|29
     28 75|13
     29 53|13
     30 
     31 75,47,61,53,29
     32 97,61,53,29,13
     33 75,29,13
     34 75,97,47,61,53
     35 61,13,29
     36 97,13,75,29,47")
     37     (assert= 143 task-1)
     38     (assert= 123 task-2)))