예제 #1
0
        public void Part1()
        {
            var answer = Day20.Part1();

            answer.Should().NotBe(-1);
            answer.Should().Be(83775126454273);
        }
예제 #2
0
        public void Part2()
        {
            var answer = Day20.Part2();

            answer.Should().NotBe(-2);
            answer.Should().Be(1993);
        }
예제 #3
0
        public void MegaTileIterationExample()
        {
            var input = @".#.#..#.##...#.##..#####
###....#.#....#..#......
##.##.###.#.#..######...
###.#####...#.#####.#..#
##.#....#.##.####...#.##
...########.#....#####.#
....#..#...##..#.#.###..
.####...#..#.....#......
#..#.##..#..###.#.##....
#.####..#.####.#.#.###..
###.#.#...#.######.#..##
#.####....##..########.#
##..##.#...#...#.#.#.#..
...#..#..#.#.##..###.###
.#.#....#.##.#...###.##.
###.#...#..#.##.######..
.#.#.###.##.##.#..#.##..
.####.###.#...###.#..#.#
..#.#..#..#.#.#.####.###
#..####...#.#.#.###.###.
#####..#####...###....##
#.##..#..#...#..####...#
.#.###..##..##..####.##.
...###...##...#...#..###";

            var megaTile = new MegaTile(input);

            var result = Day20.IterateMegaTilePart2(megaTile);

            result.Should().Be(273);
        }
예제 #4
0
 public void Part1_Example()
 {
     Day20.Part1(Example).Should().Be(20899048083289);
 }
예제 #5
0
 public void Part2_Example()
 {
     Day20.Part2(Example).Should().Be(273);
 }