aboutsummaryrefslogtreecommitdiffstats
path: root/day14
diff options
context:
space:
mode:
authorAn0nSaiko <porfeas12@gmail.com>2022-12-17 06:04:19 +0200
committerAn0nSaiko <porfeas12@gmail.com>2022-12-17 06:04:19 +0200
commitc19d3d6d50862b8847e87f018736252dc5e3129f (patch)
treebca50fe98ea7482546a7ceddbedb93531075a1d7 /day14
parentDay 15 (diff)
downloadaoc22-c19d3d6d50862b8847e87f018736252dc5e3129f.tar.gz
aoc22-c19d3d6d50862b8847e87f018736252dc5e3129f.zip
Day 16 (part1)
Diffstat (limited to 'day14')
-rw-r--r--day14/solution.nim4
1 files changed, 2 insertions, 2 deletions
diff --git a/day14/solution.nim b/day14/solution.nim
index 0056704..7816d25 100644
--- a/day14/solution.nim
+++ b/day14/solution.nim
@@ -33,7 +33,7 @@ proc parseFile(content: string): HashSet[Point] =
33 # a = begin, b = end 33 # a = begin, b = end
34 for i, a in rocks[0..^2]: 34 for i, a in rocks[0..^2]:
35 let b = rocks[i+1] 35 let b = rocks[i+1]
36 echo fmt"a = {a}, b = {b}" 36 # echo fmt"a = {a}, b = {b}"
37 for col in min(a.col, b.col) .. max(a.col, b.col): 37 for col in min(a.col, b.col) .. max(a.col, b.col):
38 let toPush = Point((a.row, col)) 38 let toPush = Point((a.row, col))
39 result.incl(toPush) 39 result.incl(toPush)
@@ -105,7 +105,7 @@ let content = readFile("./input.txt")
105let occupied = parseFile(content) 105let occupied = parseFile(content)
106 106
107occupied.draw() 107occupied.draw()
108echo fmt"{maxRow}, {minCol}-{maxCol}" 108# echo fmt"{maxRow}, {minCol}-{maxCol}"
109echo solve(occupied) 109echo solve(occupied)
110part2 = true 110part2 = true
111echo solve(occupied) 111echo solve(occupied)