Exemplo n.º 1
0
        public static void PartOne()
        {
            Console.WriteLine("Day Three - Part One");
            char[][] trees = PuzzleInputHelper.GetInputMatrix("DayThree.txt");

            int ouchies = Weeeeeeeeeeeee(trees, 3, 1);

            string displayRectangle = MatrixHelper <char> .GetDisplayRectangle(trees, new Rectangle(0, 0, 20, 20), MatrixWrap.WrapHorizontally | MatrixWrap.WrapVertically);

            Console.WriteLine(displayRectangle);

            Console.WriteLine($"You have {ouchies} ouchies. Oof!");

            Console.WriteLine("Day Three - End of Part One");
        }
Exemplo n.º 2
0
        public static void PartTwo()
        {
            Console.WriteLine("Day Three - Part Two");
            char[][] trees = PuzzleInputHelper.GetInputMatrix("DayThree.txt");

            long ouchies = Weeeeeeeeeeeee(trees, 1, 1);

            ouchies *= AnswerToPartOne;
            ouchies *= Weeeeeeeeeeeee(trees, 5, 1);
            ouchies *= Weeeeeeeeeeeee(trees, 7, 1);
            ouchies *= Weeeeeeeeeeeee(trees, 1, 2);

            Console.WriteLine($"You have {ouchies} ouchies in your kamikaze run. Oof!");

            Console.WriteLine("Day Three - End of Part Two");
        }
Exemplo n.º 3
0
        public static void PartOne()
        {
            char[][] seats = PuzzleInputHelper.GetInputMatrix("DayEleven.txt");

            string displayRect = MatrixHelper <char> .GetDisplayRectangle(seats, new System.Drawing.Rectangle(0, 0, 20, 20));

            Console.WriteLine(displayRect);

            OneRound(seats);

            Console.WriteLine();

            displayRect = MatrixHelper <char> .GetDisplayRectangle(seats, new System.Drawing.Rectangle(0, 0, 20, 20));

            Console.WriteLine(displayRect);
        }