Ejemplo n.º 1
0
        public void DoAction2()
        {
            var arcade = new ArcadeCabinet(ReadFile());

            arcade.InputQuarter(2);
            arcade.Run();
        }
Ejemplo n.º 2
0
        public void DoAction1()
        {
            var arcade = new ArcadeCabinet(ReadFile());

            arcade.Run();

            var blockCount = arcade.GetCount(ArcadeCabinet.TileType.Block);

            Console.WriteLine($"At the end there are {blockCount} blocks");
        }
Ejemplo n.º 3
0
        public static void ExecuteStarTwo(string fileLocation = "PuzzleInput/Day13.txt")
        {
            long[] program = File.ReadAllText(fileLocation).Split(',').Select(long.Parse).ToArray();
            long[] input   = new List <long>()
            {
            }.ToArray();

            program[0] = 2;

            ArcadeCabinet ac = new ArcadeCabinet(program, input);

            ac.Run();
        }
Ejemplo n.º 4
0
        public static void ExecuteStarOne(string fileLocation = "PuzzleInput/Day13.txt")
        {
            long[] program = File.ReadAllText(fileLocation).Split(',').Select(long.Parse).ToArray();
            long[] input   = new List <long>()
            {
                1
            }.ToArray();

            ArcadeCabinet ac = new ArcadeCabinet(program, input);

            ac.Run();

            Logger.LogMessage(LogLevel.ANSWER, "13A: Number of Block Tiles: " + ac.Tiles.Count(t => t.TileId == 2));
        }