From 8e90bf7002c9f96965e3d72a24b4d87ce156eddd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mika=C3=ABl=20Capelle?= Date: Wed, 13 Dec 2023 06:56:15 +0100 Subject: [PATCH] 2023 day 13. --- 2023/day13.py | 40 +- 2023/inputs/day13.txt | 1345 +++++++++++++++++++++++++++++++++++++++++ 2023/tests/day13.txt | 15 + 3 files changed, 1395 insertions(+), 5 deletions(-) diff --git a/2023/day13.py b/2023/day13.py index 992bf35..b75a5ff 100644 --- a/2023/day13.py +++ b/2023/day13.py @@ -1,13 +1,43 @@ import sys -from collections import defaultdict -from dataclasses import dataclass +from typing import Callable, Literal + + +def split(block: list[str], axis: Literal[0, 1], count: int) -> int: + n_iter = len(block) if axis == 0 else len(block[0]) + n_check = len(block) if axis == 1 else len(block[0]) + + at: Callable[[int, int], str] = ( + (lambda i, j: block[i][j]) if axis == 0 else (lambda i, j: block[j][i]) + ) + + for i in range(n_iter - 1): + size = min(i + 1, n_iter - i - 1) + if ( + sum( + at(i - s, j) != at(i + 1 + s, j) + for s in range(0, size) + for j in range(n_check) + ) + == count + ): + return i + 1 + + return 0 + + +blocks = [block.splitlines() for block in sys.stdin.read().split("\n\n")] -lines = sys.stdin.read().splitlines() # part 1 -answer_1 = ... +answer_1 = sum( + split(block, axis=1, count=0) + 100 * split(block, axis=0, count=0) + for block in blocks +) print(f"answer 1 is {answer_1}") # part 2 -answer_2 = ... +answer_2 = sum( + split(block, axis=1, count=1) + 100 * split(block, axis=0, count=1) + for block in blocks +) print(f"answer 2 is {answer_2}") diff --git a/2023/inputs/day13.txt b/2023/inputs/day13.txt index e69de29..50fe0e1 100644 --- a/2023/inputs/day13.txt +++ b/2023/inputs/day13.txt @@ -0,0 +1,1345 @@ +....#....#. +..##.####.# +####.####.# +####..##..# +######..### +....##..##. +.....####.. +####......# +..##.####.# +..##..##..# +..#.#.##.#. +###.##..##. +#.#.#.##.#. +####.####.# +#####.##.## + +.#......##.#.#... +.##.#..######.#.. +..#.##..#..##.### +##....#######...# +...##..#.#...###. +...##..#.#...###. +##....#######...# +..#.##..#..##.### +.##.#..######.#.. +.#......##.#.#... +.#.########....#. +..##.##.#..##.##. +..##.##....##.##. +.#.########....#. +.#......##.#.#... +.##.#..######.#.. +..#.##..#..##.### + +##..####..### +.#..####..#.. +#...#..#...## +##.#....#.### +...#.##.#.#.. +.###....###.. +#.########.## +#..##..##..## +.#.#....#.#.. + +...##.#..#.##.. +..##.#.##.#.##. +###.#..##..#.## +###.#......#.## +..##..#..#..##. +..#....##....#. +....##.##.##... +####.######.### +....#.####..... +..####....####. +..###.#..#.###. +###..######..## +...#........#.. + +...##..###..... +..#....#..##... +...#.###.#.##.. +...#..##.#.##.. +..#....#..##... +...##..###..... +#.##.########.# +#....#.#.#..#.. +###....###..##. +...###..###.### +#..#...#..#..#. +#####.#........ +#..##.#...#..#. +#..##.#...#..#. +#####.#........ +#..#...#..#..#. +...###..###.### + +..##....# +....####. +####....# +##....... +....#..#. +....####. +..#...... +..#...... +###...... +###.###.. +..##.##.# +###...... +...#.##.# + +.#...#.#.#. +.#...#...#. +..######.#. +.#.###.#.#. +.##...#.#.. +.#..#...... +..#.....#.. +#.##.#.#.#. +.....##.### +.....##.### +#.##.#.#.#. +..#.....#.. +.#..#...... +.##...#.#.. +.#.###.#.#. +..######.#. +.#...#...#. + +#.#...##..# +####..##.#. +#..#....... +#..#....... +####..##.#. +#.#.#.##..# +...#.#####. +##..#.##... +#.#...#.... +##.#.#.#.## +.###...#.## +.#.#.###### +.#.##.#..## +.##.##.##.# +.##.##.##.# + +#.....# +.##..#. +.####.# +.####.# +.##..#. +#.....# +#####.. +#####.. +#....## +.##..#. +.####.# + +...#.##.#.. +#...##...## +#..##....## +.####.#.### +.##.###.#.. +...#.###### +#.#..###.## +#.#..###.## +...#.###### +.##.###.#.. +.##.#.#.### +#..##....## +#...##...## + +.#####..# +...##.##. +#.###.... +#.###.... +...##.##. +.#####..# +######..# +..##...#. +...#..##. +##..#.##. +.##...... +....#.##. +..####..# + +.#....#.###...### +.######..##.#..#. +.######..##.#..#. +.#....#.###...### +#.####.#....#.#.. +...........#..... +.#.##.#.#.##....# +#......##.##...#. +#..##...##.....#. +.##..##..#.###..# +.#.##.#.#...#.#.. +#......#.#..#.#.# +###..###.#..##... +.######.#.#.#.##. +#..##..#.#....#.# +..#..#.....#.##.. +#.####.#.#.##.#.. + +...##.##.##.. +..#.....#..#. +..#.#....#.#. +###.##..##.## +...#.####.#.. +..##..##..##. +..#.#.##.#.#. +##..........# +.....#..#.... +...#.####.#.. +..##..##..##. + +##.#.#.#. +.##..#### +...#.#... +..#.#..## +.####.... +.###..... +.#....### +...##..## +#.#.#.#.. +#.##.#.## +##...#.## +####..#.. +.#..##... +.#...#### +##...#... +...####.. +...####.. + +......##.##.# +........#..#. +##..##.#.##.# +#....###....# +.####.#...... +##..#####..## +..##..#.#..#. +##..######### +#....#.#..#.# + +.##.##.#.##..##.# +#######..#....#.. +####.#.#.#....#.# +#..##...#..##..#. +####.#...#.##.#.. +#..#...........#. +.##..#........... +####.#.########## +####.##.########. +####..##.##..##.# +....#.########### +#..#.......##.... +....#.###.#..#.## + +#..##..########.. +##.##.###.##.#..# +..#..#...#.#..#.. +...##....#...#..# +##....####.#.###. +##....#####.##... +##....###.#....#. +..####.#..##....# +#..##..#.#.#..### +.........#.#....# +##.##.#####.##..# +##.##.#####.##..# +.........#.#....# + +...####.#####.. +.###..####.#... +.###..####.#... +....###.#####.. +####...#.#..### +##.###.##..#### +.########.##### +###.###.#...... +####..####.##.# +####..####.##.# +###.###.#...... +.########.##### +##.###.##..#### +####...#.#..### +....###.#####.. + +##.##..## +##.##..## +##.####.# +.....#..# +###.#.#.. +.##..#... +###...... +###...... +.##..#... +.##.#.#.. +.....#..# +##.####.# +##.##..## + +#.#.#..##...##. +#.#..#.#.##.... +##......#.#.##. +.##.##..###.##. +...#.###.#.#..# +...#.###.#.#..# +.#..##..###.##. + +##.#......#.### +#...#..#.#...## +##.#......#.### +#####.##.###### +###.##..##.#### +#.##.####.##.## +..#.#....#.#... +.##........##.. +#..##.##.##..## +....#....#..... +..####..####... +.##.##..##.##.. +###.#....#.#### +.#.#.####.#.#.. +##...####...### +..#..####..#... +###...##...#### + +..##### +##..... +.#..#.. +.#..#.. +##..... +..##### +..#...# +##....# +#####.. +..###.. +#.###.. +#####.. +##....# +..#...# +..##### +##..... +.#..#.. + +#.##.#.###### +##.#..####### +#...#.#...... +#...#.#...... +.#.#..####### +#.##.#.###### +#..###...##.. +#.####.#....# +..####.#.##.# + +#.#######..##...# +..##..###.#.##..# +..#...#.######... +..#...#.######... +..##..###.#.##..# +#.#######..##...# +...####...#####.# +#..#.#..##..#.### +.#.#.#..###..#.#. +####..#.###.#.... +.....##.#.####..# +.....##.#.####..# +####..#.###.#.... +.#.#.#..###..#.#. +#....#..##..#.### + +##..###.##.## +###..#.....## +.##..#.###.## +...##.....#.. +###..#.###.## +..#...#.##### +..##..#.#.... +#.##.####.#.. +.#...#.#.#.## +.#...#.#.#.## +#.##.####.#.. +..##..#.#.... +..#...#.##### +###..#.###.## +...##...#.#.. +.##..#.###.## +###..#.....## + +..#..#.#. +.##.#.### +.##.#.### +..#..#.#. +.###.##.. +.##...#.. +.#......# +#.#.##.#. +#.#.##.#. +.#......# +.##...#.. +.#.#.##.. +..#..#.#. + +.##..#. +.#.##.. +#.#.... +#.#.... +.#.##.. +.##..#. +#...#.. +###...# +.###... +##.#.## +##.#.## +.#.#... +###...# +#...#.. +.##..#. + +#.###..#.##.# +#..###.###### +.#.#..##....# +.#.#..##....# +...###.###### +#.###..#.##.# +#.#...#..##.. +#.....#...... +####.#..#..#. + +.#.#### +..#..#. +#..##.. +..#.... +##...## +.#.##.# +.##..## +.##..## +.####.# +##...## +..#.... +#..##.. +..#..#. +.#.#### +.#.#### +..#..#. +#..##.. + +.#...###..... +..#.#.######. +##.....#.#..# +.#.....#.#..# +..#.#.######. +.#...###..... +..#..#...#..# +#..#..#....## +#..#..#....## + +##.##.##.#....# +..######.#..### +....##..#.#..## +#..#.###.##.... +#..#.###.##.... +....##..#.#..## +..######.#.#### +##.##.##.#....# +.#....####..... +##.###.##.##.#. +......####..#.. +.###.#.#.....## +..##.#..#....#. +###.....##...## +##.#####....##. +...####..#.#..# +...####..#.#..# + +##.##.#...##.#.#. +##.##.#...#.#.##. +##..##.#.###.#.#. +...#.#.#.#....### +##.##....#....##. +##.##....#....##. +...#.#.#.#....### +##..##.#.###.#.#. +##.##.#...#.#.##. +#####.#...##.#.#. +..#.#...###.#.### +..#...#....##.##. +..#..#..#.###.#.. +####..#.#.#####.# +...######.####..# + +..###.####.###. +####.#.##.#.### +...#.#....#.#.. +..##..#..#..##. +##.####..##.#.# +##.#.#.##.#.#.# +.....#....#.... + +...##..##.##. +.###...#.##.. +#.#...#.#.... +#.#...#.#.... +.###...#.##.. +#..##..##.##. +###.#..#....# +#..##.#....## +#..#..##..#.# +.....##..#..# +.####..#..### +#####..###.#. +.#.#.....#.## +.#.#.....#.## +#####..###.#. +.####..#..### +.....##..#..# + +#.###.#...###.# +....#..#..#.##. +#..#..#...###.# +.###.#..#.##### +#...#....##..#. +####.#.....#### +...#####.##..## +...#####.##..## +####.#...#.#### +#...#....##..#. +.###.#..#.##### +#..#..#...###.# +....#..#..#.##. +#.###.#...###.# +#.###.#...###.# + +######.##.# +#.##.###### +..##..####. +#.##.#....# +#....#.##.# +.####...... +#...##....# + +#.##### +..#.#.. +#...#.. +##.##.. +....##. +###.### +...#### +.##.... +#.#.### +#..#.## +#....## +..##... +..##... + +..#...##...#. +...#..##..#.. +...##....##.. +.....#..#.#.. +#####.##.#### +##...#..#...# +...#.####.#.. +####.####.### +..##.####.##. +###.######.## +###..#..#..## + +..####...#.##..## +####.#.......##.. +......##..#..##.. +#.....#####...... +.#.###...#....... +..#.#..#.#...##.. +....##.##.####### +###.##...#.#.##.# +.##....###.##..## + +..##....##.#..#.. +..##....##.#..#.. +##..###.......#.. +#.##.###..#.#.### +.#..###.#######.# +.####.###.##....# +.#..#.#..#..##.#. +#....##.#.##..#.. +#########.#.##### +.......#...#..### +#######.#..#...## +##..####...####.. +.#..#..#.#.##.... + +....#.. +##.##.# +#.####. +#.####. +##.##.# +###..## +..#..#. +..#..#. +###..## + +.####.. +######. +.####.# +#....#. +..##... +..##... +#....#. +.####.# +.####.. + +###.##.####.... +.##....##...##. +..##..##....... +..##..##...#..# +.#.####.#.##..# +##.#..#.###.##. +...#.......#..# + +#####.#.##. +#..##...... +#..#..#.... +.##....#..# +####....##. +.....##.##. +....####### +....#...##. +######..... +#..#..##..# +#####.#.### +#####...... +.##.#..#..# +#..#.###### +....#..#..# + +###..##.##.##.##. +##.#.#....#.#..#. +#.#.....#.##.#..# +..##.###.#.#..... +...##..#...#..... +..##.#..##...#### +.#..#.#..#...#..# +###...#...#.#.... +#..##....#.###..# +#.#.#.......##### +.#.##...#.###.... +.#.##...#.###.... +#.#.#.......##### + +.#...#.##.#...#.. +#.##.#.##.#.##.## +...#..#..#..#.... +..#.##.##.##.#... +###..#....#..#### +###..#....#..#### +#..#.######.#..#. + +.##..###. +#..#...## +#..#.#### +.......## +#..#..... +#####.... +.##.##.## + +####.###.#. +####...#.#. +#...#....## +#..##..#.#. +#..#.#.#..# +#..#.##.##. +#..##..##.# +.##..##.#.# +.##.#..###. +########... +########... +.##.#..###. +.##..##.#.# + +..#.##.#### +###.###.##. +##..###.... +##...##.... +###.###.##. +..#.##.#### +.#...##.... +...##...... +.#.#.##.... +#.###.#.... +..#..##.##. + +##...#...#... +##...#..##... +#...#...##### +#.#..#....... +#.#####.#.... +#####..####.. +..##.##.#..## + +.#####. +.#.#..# +#.###.# +.#.#### +#.#..#. +.#.##.. +.#.##.. +#.#..#. +.#.#### +#.###.# +.#.#..# +.#.###. +.#..### +.#..#.. +.#..#.. + +#.#..#.#.######.# +#.#..#.#.######.# +.........#.##.#.. +...#..#..##..##.. +.#.#.####......## +.###.##..######.. +###..####.##.#.## +..#######.#..#.## +#..##...#.####.#. +##.##.#..##..##.. +##.#.#.#..#..#..# +#..##.#.......... +##.##...##.##.##. +.#..####.######.# +..###..##.####.## +....####..####..# +#..##....#....#.. + +..####..#..##.. +.#....#.#.#..#. +.##..##..###### +#..##..###.##.# +.##..##....##.. +....#...#..##.. +..####..#...... + +##.###.#####... +##.##...#..#.## +##.##...#..#.## +.#.###.#####... +####.####.#.### +##...#####..### +#.###.#.####### +..##.#..####... +.###..#####.#.. +....#.#.##..### +#....#.#.##.#.. +#..#..#.#####.. +....#..####.### +.#...####.##### +###.#.#.##.#### + +#..#..#..##.# +#..#.#.##.#.# +.##...#..#... +####.#....#.# +#..##.####.## +#..##......## +####...##...# + +#...##.##.# +##.##..#.#. +.###..##..# +.###..##..# +##.##..###. +#...##.##.# +#........#. +#........#. +#...##.##.# +##.##..###. +.###..##..# + +.#..########. +#...#....#.## +...#.#.#.#..# +########.#..# +########.#..# +...#.#.#.#..# +#...#....#.## +.#..########. +##.###.#...#. +#...##..#.##. +###.....#...# +#.#.#...#.... +#....####..#. +#.....###..## +..#####..#.#. +#.##.#.#...## +#.##.#.#...#. + +#.###...####...## +...##..#....#..## +.##..#.##..##.#.. +#.#.#....##....#. +##....#......#... +##.....#....#.... +....#.#......#.#. +#.##..#.####.#..# +#...##.#.##.#.##. +#...##.#.##.#.##. +####..#.####.#..# +....#.#......#.#. +##.....#....#.... + +#.###.#...#.. +##...#...#.## +.......###... +.####.##.#### +##.###..##... +....#####..## +##.###.#.#### +.###..##.#.## +.##.#....#### +..#.....#.### +####..#....## +###.....#..## +#.#.#.#.#.#.. +#.#.#..##.### +#.#.#..##.### +#.#.###.#.#.. +###.....#..## + +###..###.#.#. +#.#..#.###..# +#.#..#.###.#. +##....###.#.. +.#....#..###. +...##...#..#. +#..##..#..#.# +#..##..#..#.# +...##...#.##. +.#....#..###. +##....###.#.. +#.#..#.###.#. +#.#..#.###..# +###..###.#.#. +.######.#..#. + +#..##.#...#.#.. +.#...###.####.# +.###.##.#...... +#.#.#..####.... +#.#.#..####.... +.###.##.#...... +.#...###.####.# +#..##.#...#.#.. +.##.###.#.#.##. +.##.###.#.#.##. +#..##.#...#.#.. +.#...########.# +.###.##.#...... + +....#.####....### +...##.#.########. +.....#........... +####..#.......... +.##.#.#.#.#..#.#. +####.#..#.####.#. +#..#.####.#..#.## +....#....#.##.#.. +#####..#...##...# +.##.###...####... +.##..##...#..#... + +#..#..###...#.# +####..#.#....#. +........##...## +###.#.#.#....## +..#...#.#.###.. +.....##...#..## +...#..#.#..#### +##.#...##..#... +##.#...##..#... +...#..#.#..#### +.....##...#..## +..#...#.#.###.. +###.#.#.#....## +........##...## +####..#.#....#. + +.....#.##.#.. +##....####... +..#...#..#... +###.##....##. +##...##..##.. +####.#....#.# +##..########. +.....##..##.. +##.##..#...## +..###......## +##...#.##.#.. +##..########. +...########## +..##...##...# +...###.##.### + +##......####..#.. +##.#..#.###....## +##..##..##.#.#..# +##..##..##.#.#..# +##.#..#.###....## +##......####..#.. +.##.##.##...#..## +.#..##..#.##....# +##########...#### +###.##.###...#.#. +#.#....#.#..###.. +.#..##..#.#.#.#.# +.########..#..##. +##########.###... +..####.#..#.##.#. +...#..#...##.##.. +##.#..#.####..#.# + +..##.....#..#.. +.#..#.#.#.##.#. +#.##.#.#.####.# +######.#######. +##..##.#..##..# +##..##..#.##.#. +......#..#..#.. +#....##.##..##. +.#..#.####..### +######..##..##. +######.###..### +.####...#.##.#. +#.##.#.#......# + +..##.#. +######. +#.##.#. +.####.# +##..##. +..##..# +.####.# +.####.# +..##..# + +###..#. +##..#.# +...##.# +..##..# +...##.. +##..#.# +..##.#. +..#.... +......# +......# +..#.... +..##.#. +##..#.# +...##.. +..##..# +...##.# +##..### + +.###...##.... +##..##.#..##. +####..##..##. +#...##...#... +.########.##. +..###..###### +....##.##.... +#...##.#.#### +..##.##.#.... +#...##.#..##. +..#.###...##. +..#.###...##. +#...##.#..##. +..##.##.#.... +#...##.#.#### + +....#.####. +......##..# +.....#..##. +#..###.#### +#..##..#### +#..##.##... +......###.# +....#..#.## +.....#..#.. +####.#..##. +####.#..#.. +####.#..#.. +####.#...#. +.....#..#.. +....#..#.## +......###.# +#..##.##... + +########......# +...##...######. +...##...##..##. +.##..##..#..#.. +..####..#.##.#. +#......#......# +......#........ + +###...#.##### +###...#.##.## +#########.#.. +..#.#.#.##..# +....#..#..... +..###.##..##. +##.####..#### + +...##.#.. +..##.#.## +#.##..### +.#..##### +..#...#.. +.#.###### +.######## + +...###. +...###. +..#.#.. +.#.##.# +.#...#. +#.###.# +#.###.# +.#...#. +.#.##.# +..#.#.. +#..###. + +.##..## +....#.. +##..#.. +#.#.... +#.#.... +##..#.. +....#.. +.##.### +#..#.## + +.##.###.#.# +#....##..#. +#.#.#.####. +#.#.#.####. +#....##..#. +.##.###.#.# +#.#.######. +##.#..##..# +#...#...#.# +##...#..#.# +.#.#.#.#... +.#.#.#.#... +##...#....# +#...#...#.# +##.#..##..# + +##.#..###...# +###.##......# +####.#..###.# +....##....#.# +...#.##.#...# +###.#..###### +.....####.... +.....####.... +###.#..###### +...#.##.#...# +....##....#.# +####.#..###.# +###.#.......# +##.#..###...# +####.######## + +....#....## +####..#.#.. +#####....## +#..##...#.# +#..#.....## +#..#..#..## +....#.#.#.. +....###.### +......#.### +#######..## +######.#.## + +.####..###### +#....##..##.. +#.##.#..#..#. +......#.####. +#######..##.. +#.##.##..##.. +.####.#.####. +#######.#..## +##..##.#.##.# +#....#.#....# +.####..#.##.# +#....##...... +#....###....# +......#.####. +.####..###### + +...##.... +##...#..# +#..#####. +.#.##.#.. +..####..# +###...### +###...### +...###..# +.#.##.#.. +#..#####. +##...#..# +...##.... +.#.#..#.. +.#.#..#.. +...##.... +##...#..# +#..#####. + +..##..#..#.#.#.## +..##..#..#.#...## +....##.####..#.## +#.#...#.###.###.. +##.#.###.#...#... +##.#.###.#...#... +#.#...#.###.###.. +....##.####..#.## +..##..#..#.#...## +..##..#..#.#.#.## +##....###..#..#.# +......#.#.....##. +#.#..#####......# +.###..##.#.#.#..# +..#.###..#.##.### + +###.##....##.## +#..##.####.##.. +#..##.####.##.. +###.##....##.## +.#..##.##.##..# +##.....##.....# +..#.##....##.#. +.#....#..#....# +##.##.#..#.##.# +..#..........#. +#..##......##.. +#......##....#. +##...##..##...# + +.....##..##..## +..#..#.##.###.# +..##..#..##..#. +..#.##.#.##.#.# +#.#..##.####.## +..#.....####... +.#...#.######.# +#.#............ +#.#............ +.#...#.######.# +..#.....####... +#.#..##.####.## +..#.##.#.##.#.# + +.......##.# +.##..#.#..# +.##..#.#..# +.......##.# +#..###..### +####.#####. +#..###.#### +......##.## +.#..####.## +#..###...## +.......##.. + +##.#.#.#..##... +#.#..####.##..# +...##..#.#.#### +#.##...######.. +#..###..#.#.#.. +##..####.##..## +#..#....#.#.### +#..#....#.#.### +##..####.##..## + +.#....... +.#....#.. +.#....#.. +.#....... +.####..## +..##.##.# +.#....... +####....# +###..##.. +.##.#..#. +.######## + +..#....#... +..######... +..#....#... +#..#.##..## +#...##...## +.##....##.# +#...##...#. +#...##...#. +.##....##.# + +.###..# +.##.... +..####. +.##.### +#..###. +.###.#. +.###.#. +#..###. +..#.### +..####. +.##.... +.###..# +.###..# +.##.... +..####. + +.##..## +#...... +..####. +#..##.. +.##..## +#..##.. +###..## + +##....##. +....#.#.# +#...#.#.# +##....##. +..#..##.. +...##..#. +.#......# +.#.#.#.## +.#.#.#.## + +###...#.# +......#.# +###.###.. +###.###.. +......#.# +###...#.# +..#####.# +##.....#. +.##..##.# +...#####. +####..#.# + +...#....#.....# +..########..#.. +..#......#..##. +..########...#. +##..####..##..# +##.######.##... +....#..#.....## +###..##..#####. +.#..#..#..#...# +..#.####.#...#. +...######....## +###......#####. +##..####..##..# +###......####.# +..#.#..#.#..##. +####.##.#####.# +..#......#..### + +...#..####.##...# +.##.#.#..#.#.##.# +.##...####...##.# +..###......###..# +#.#.#......#.#.## +...#.##..##.#.... +.#...#....#...#.# +##..#......#..##. +#..#.######.#..## +###...####...#### +###...####...#### +#..#.######.#..## +##..#......#..##. +.#...#....#...#.# +...#.##..##.#.... + +.#.#.##.#.### +#.#.#..#.#.## +###..##..#### +.##......##.. +.##.#..#.##.# +############. +############. +.##.#..#.##.# +.##......##.. +###..##..#### +#.#.#..#.#.## + +##...#...#...#### +#...##.##.....### +#...##.##.....### +##...#...##..#### +#.#.####......... +#####..#...#.##.. +#.....#.#....#... +.#.....##..##.#.. +##.#.#.###..##### + +##....#.#...####. +##....#.#...####. +###.##.#.##.##### +#..#.##.##..##... +.#..#..........## +###.####.#.#####. +.#....#.#.#.#.#.. +.#...##.###.#..## +.#....#.###.#..## +.#....#.#.#.#.#.. +###.####.#.#####. +.#..#..........## +#..#.##.##..##... +###.##.#.##.##### +##....#.#...####. + +#.##.## +##..### +..##... +.#.#... +#...... +..###.. +.####.. +#.###.. +..###.. + +##.......##.... +####.#..#..#..# +#...####....### +###.#.#..##..#. +##..#.#..##..#. +#...####....### +####.#..#..#..# +##.......##.... +..##....####... + +#.#.######.#.#### +##.#.#..#.#.##### +###.#....#.###### +#..#..##..#..#..# +.#...#..#...#.##. +#..###..###..#### +.##..#..#..##.##. +.#...####...#.##. +....##..##....... +..##.#..#.##..##. +.....#..#..#..##. +##.###..###.##### +.#.##....##.#.... + +.####..####..#..# +#.#..##..#.#.##.. +..##....##....##. +.#..#..#..#.#..## +#....##....#.#.#. +.#..#..#..#.##### +#....##....##..## diff --git a/2023/tests/day13.txt b/2023/tests/day13.txt index e69de29..3b6b5cc 100644 --- a/2023/tests/day13.txt +++ b/2023/tests/day13.txt @@ -0,0 +1,15 @@ +#.##..##. +..#.##.#. +##......# +##......# +..#.##.#. +..##..##. +#.#.##.#. + +#...##..# +#....#..# +..##..### +#####.##. +#####.##. +..##..### +#....#..#