set up day 6
This commit is contained in:
parent
c6b91e6ed3
commit
6b9d579764
3 changed files with 156 additions and 0 deletions
130
day_06/input.txt
Normal file
130
day_06/input.txt
Normal file
|
|
@ -0,0 +1,130 @@
|
||||||
|
..................#................................................................#........#.....................................
|
||||||
|
...#...........#...................................................#........................................#.................#...
|
||||||
|
...................................#................#.#...............#.................................................#.........
|
||||||
|
.....#......#................#.....................................................................#..........#........#......#...
|
||||||
|
............................................................................................#.....................#...............
|
||||||
|
.....................#..##...#........................#.................#.......................#..#.........#.......#...#......#.
|
||||||
|
............##....................................##..................#...............................#....#......................
|
||||||
|
.............#............#.#..#.......#...........#..............#...............#.....#.........................................
|
||||||
|
....................#..........##.........#.........#................#............................................................
|
||||||
|
....#.......#................................................................#...#.#..........................................#.#.
|
||||||
|
..#..............#.....................................#..........#.#....#..............#..................#.#............#.......
|
||||||
|
.#.......#.........................#........................#..#.....#............................................................
|
||||||
|
........#...#......................#...........#......................................#....................#......................
|
||||||
|
.............................#..............#........##....#....................#......#....................#............#......#.
|
||||||
|
..............#..............#............#.......................##....#..........................................#.........#....
|
||||||
|
.............#............#..........#..........#...#.....................................................#.......................
|
||||||
|
..#........#.....#..........................................#................................................#...#.#...#..........
|
||||||
|
........#.....................#...#..#......#.........................................................#.....##.........#..........
|
||||||
|
..............................................................................................#...#...............................
|
||||||
|
..#.......................#..........................#......#...................................................................#.
|
||||||
|
.......#.........................#..............#.........#.............#.......................................#...#.............
|
||||||
|
..................#.................#.......................#....................#....................................#...........
|
||||||
|
...#...#.......#......##.#...............#....#..............#..........................................#....#..#.................
|
||||||
|
#................................#.......#.....#.......#.............#..................#........#................................
|
||||||
|
...........#..................................#.......................................................................#.#..#......
|
||||||
|
.......#........#.........................................#..........................#...........................#.....#..........
|
||||||
|
................#..#.....................#..#...........................#...........................................#.............
|
||||||
|
#...#.......................#................................................#................#................................#..
|
||||||
|
..........#...........................#.......#............................................................................#.....#
|
||||||
|
..................................#............................................................#..................................
|
||||||
|
......................#........#.............#....#.....#.......#..........................#..........................#...........
|
||||||
|
...........................##.................#.............#........................#...#..................#.....................
|
||||||
|
.............................................................................................................#....#..........#....
|
||||||
|
................#...................................#...........#..........#....................#............................#....
|
||||||
|
........#....#................................................#................##..#..................................#...........
|
||||||
|
...........#....................................................#...#.#......#....................................................
|
||||||
|
.......................#.........................................................^....................................#...........
|
||||||
|
..........................#.............##..#........#.#....#.......#....................#...........#.........#.....#............
|
||||||
|
........#...........................#..#..........................................................#...............................
|
||||||
|
....#....................................#....#.........................................#.........#...............................
|
||||||
|
...............#...................................#.....#.................................#....................................#.
|
||||||
|
......#...............................................................#.............................#........................#....
|
||||||
|
.........................#.....#.........................#.#...............#.........#.....#..................#..#.........#......
|
||||||
|
.........................................................#......#........##.......................#...#......#................#...
|
||||||
|
.......................................#.....#.................................#..................................................
|
||||||
|
..................#..................................#..........................................................................#.
|
||||||
|
...................#....#.........#.......#................#....................#.........................#......#.....#..#.......
|
||||||
|
................................#..............................................................................#....#.............
|
||||||
|
.....................#.#.............#.................#..........#.......#.........................................#.............
|
||||||
|
......#....................#....................................................................#...#.............................
|
||||||
|
........#........#...........#.##.............#........................#............#..............#.........#....#........#......
|
||||||
|
........................#.................................................................#.......................................
|
||||||
|
............................................................#.....#....................#............#.....#....#............#.....
|
||||||
|
...........#............#....#........................................................##............#..............#..............
|
||||||
|
...........#...........#.....#..............#..............##....#........#......#................................................
|
||||||
|
..#................................................................................#......................#......#................
|
||||||
|
....................#.........#......................#.............................#.......#.......................#.............#
|
||||||
|
..#...#....#......................................................................................................#...............
|
||||||
|
...........#................................................................................#...............................#.....
|
||||||
|
....................................#............#..........#.........................#..................................#.......#
|
||||||
|
...................#......#...................#............#......#........#................#.............#...........#.........#.
|
||||||
|
........................#..................................#........#..................#..........................................
|
||||||
|
............#..#...........#..................##....................#...........................................#.................
|
||||||
|
.......................................................................................#.....#............#.......................
|
||||||
|
...............................................#....#................................#..#..........................#..#...........
|
||||||
|
..............#..#.....#.........#....................#.......#..#..............#...............................#.....#...........
|
||||||
|
..........#............................#..........................................................................................
|
||||||
|
........................................#........#........................................................#.#.....................
|
||||||
|
#................#......................#..................................................................................#......
|
||||||
|
...............................................................................#................................#.................
|
||||||
|
...................................................................................................................#.#........#...
|
||||||
|
#........................................................................#......................................#.#...............
|
||||||
|
...#......#............#...................#.............#........#..........................................#......#.............
|
||||||
|
..............##....#...................................................#......................#..................................
|
||||||
|
...............#........................................................................#...........#...#.#.......................
|
||||||
|
..........#.#.....#................................#...........#........#.......#.................................................
|
||||||
|
#....................#......................................................................................#.....................
|
||||||
|
..............#...##...........................................#.............#.......#..................#..............#..........
|
||||||
|
.#.............................................#..............................................................................#...
|
||||||
|
...#................................#............................................#............................#...................
|
||||||
|
..............................#......................................................#..........................................#.
|
||||||
|
...................#.....................................#..................................#......#..............................
|
||||||
|
....#.#..........##.............#.......#........................##..........#.................#..................................
|
||||||
|
#..#................#........##....................................................................................#..............
|
||||||
|
........#...#.........................................................................#...........................................
|
||||||
|
......................................................#....#...................#..#.................................#.............
|
||||||
|
........#...............#........#..............................................#............................#....................
|
||||||
|
...#..............................#.........................................##.......................................#....#.......
|
||||||
|
...#................#..............#.......#......................................................................................
|
||||||
|
........#..................#.............................................................#...........................#....#.......
|
||||||
|
......................#.#..........#.......#..................................#..#...#............#...............#...............
|
||||||
|
.....#..................#....#..#......#.......................#.....................................................#............
|
||||||
|
.....#................................#.........................#..................#.#..........#...#............#.....#..........
|
||||||
|
....#...................#....#.#.........#........#..................................................................#....#..#....
|
||||||
|
........#...............#......................................#........#..............................#..........................
|
||||||
|
....#...#.#.....#..............#..................#..........#...#..#......................#...#..........#......................#
|
||||||
|
...........#...................................................................................................#................#.
|
||||||
|
.................................##..............#.............................#...............................#..................
|
||||||
|
...........#.................#.............##...................................#.......................#.................##......
|
||||||
|
.....#..................#......#........#.................................................#..#........................#..#........
|
||||||
|
......#.......#......................................................................#.#.........#....#...........................
|
||||||
|
..................#.#........................#......#................................................................#......#.....
|
||||||
|
.....................#............#...................#.....#....................................#.......#..........#.......#.....
|
||||||
|
#.............................#...............................#...#...............................................................
|
||||||
|
..##.........#........#......................................#.....................#...#.............#............#..#............
|
||||||
|
..........#.....................#..#....................#...#....................#....................#.....................#.....
|
||||||
|
...........#..........#...............#..#..........#..............................................#.#............................
|
||||||
|
............#...#...#.............#.........#.............................#...............#.......................................
|
||||||
|
.........#...........#...............................................................#............................................
|
||||||
|
.#..#.................................................................#............#.#.......................##...................
|
||||||
|
........##............#...................#................................#......................................................
|
||||||
|
............................................#..........................#..........................................................
|
||||||
|
#...................#...........#..............#...#............#.#........#.................#......#.............................
|
||||||
|
........#....................................#....................................................................................
|
||||||
|
...........#.........#..#...............#...........#.....##.#......#....##............#....#....#.#.........##.........#.........
|
||||||
|
..#......................#..........#.................#.................#......#.............................#........#...........
|
||||||
|
....................#.................#....#..............................#....#.............#....#....#.....................#....
|
||||||
|
............#.................#.................................#...............................#..#...........................#..
|
||||||
|
...................................................#.....#..............#.......#....................#.#..........................
|
||||||
|
..#.........##..#........#...................................................................................#............#.......
|
||||||
|
.....#..............................#......................................................................#........#.............
|
||||||
|
................................#........##.......#...............#..............#.......#...#.#........#.........................
|
||||||
|
..............................#.....................#.........................................#..................................#
|
||||||
|
...........#...................##.................#.................................#...............................#........#....
|
||||||
|
..............................#...##......#..................#...#................................#......#.......#...............#
|
||||||
|
.....................##......#......#.#.......#..............#......#.................#.........#...................#.............
|
||||||
|
..........................#................................#...........#..........................................................
|
||||||
|
...#.....#....................#.....................#...#.....#.............................#.#....#.....#.#.................#....
|
||||||
|
............................#...#........#......................................................................#.....#...........
|
||||||
|
............#..........##..................#.............................................................#.....#..#...............
|
||||||
16
day_06/program.py
Executable file
16
day_06/program.py
Executable file
|
|
@ -0,0 +1,16 @@
|
||||||
|
#!/usr/bin/env python3
|
||||||
|
|
||||||
|
# https://adventofcode.com/2024/day/6
|
||||||
|
|
||||||
|
def get_lines(filename: str) -> list:
|
||||||
|
with open(filename, "r") as file:
|
||||||
|
return [line.strip() for line in file.readlines()]
|
||||||
|
|
||||||
|
|
||||||
|
def main():
|
||||||
|
lines = get_lines("sample-input.txt")
|
||||||
|
# lines = get_lines("input.txt")
|
||||||
|
|
||||||
|
|
||||||
|
if __name__ == '__main__':
|
||||||
|
main()
|
||||||
10
day_06/sample-input.txt
Normal file
10
day_06/sample-input.txt
Normal file
|
|
@ -0,0 +1,10 @@
|
||||||
|
....#.....
|
||||||
|
.........#
|
||||||
|
..........
|
||||||
|
..#.......
|
||||||
|
.......#..
|
||||||
|
..........
|
||||||
|
.#..^.....
|
||||||
|
........#.
|
||||||
|
#.........
|
||||||
|
......#...
|
||||||
Loading…
Add table
Add a link
Reference in a new issue