From 2543975e2d3d6d5d5f5173beed5b7972d5e40ba7 Mon Sep 17 00:00:00 2001 From: Sven Weidauer Date: Sat, 25 Dec 2021 17:59:43 +0100 Subject: [PATCH] Reimplement day 22 part 1 together with part 2. --- day22.swift | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/day22.swift b/day22.swift index a27b374..2bc5051 100644 --- a/day22.swift +++ b/day22.swift @@ -31,19 +31,35 @@ struct Day22: Puzzle { let firstY = ySteps.removeFirst() let firstZ = zSteps.removeFirst() + var part1 = 0 var part2 = 0 var x0 = firstX for x in xSteps { let possibleX = cubes.filter { $0.xRange.overlaps(x0..