Пример #1
0
        public void PartTwo()
        {
            var input = Helpers.FileHelper.ParseFile(InputFile);

            var map = new SeatingMap(input, tolerance: 5, searchFirstVisible: true);

            map.SimulateSeating();

            Assert.IsTrue(map.Occupied == 2045);
        }
Пример #2
0
        public void Test_KnownVisibleSeats()
        {
            var input = Helpers.FileHelper.ParseFile(TestFile);

            var map = new SeatingMap(input, tolerance: 5, searchFirstVisible: true);

            map.SimulateSeating();

            Assert.IsTrue(map.Occupied == 26);
        }
Пример #3
0
        public void PartOne()
        {
            var input = Helpers.FileHelper.ParseFile(InputFile);

            var map = new SeatingMap(input);

            map.SimulateSeating();

            Assert.IsTrue(map.Occupied == 2265);
        }
Пример #4
0
        public void Test_KnownAdjacentSeats()
        {
            var input = Helpers.FileHelper.ParseFile(TestFile);

            var map = new SeatingMap(input);

            map.SimulateSeating();

            Assert.IsTrue(map.Occupied == 37);
        }