diff options
Diffstat (limited to 'Day13.cs')
-rw-r--r-- | Day13.cs | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/Day13.cs b/Day13.cs index 681126d..4dff712 100644 --- a/Day13.cs +++ b/Day13.cs @@ -11,14 +11,12 @@ namespace aoc2019 private readonly IntCodeVM vm; - public Day13() + public Day13() : base(13, "Care Package") { vm = new IntCodeVM(Input.First()); board = new Dictionary<(int, int), int>(); } - public override int DayNumber => 13; - private void UpdateTiles(IEnumerable<long> queue) { var input = queue.Select(i => (int) i).ToList(); @@ -65,9 +63,9 @@ namespace aoc2019 { vm.Reset(); vm.memory[0] = 2; - var printboard = false; + var printBoard = false; var gameTicks = 0; - if (printboard) Console.Clear(); + if (printBoard) Console.Clear(); var haltType = IntCodeVM.HaltType.Waiting; while (haltType == IntCodeVM.HaltType.Waiting) @@ -80,7 +78,7 @@ namespace aoc2019 vm.AddInput(ball > paddle ? 1 : ball < paddle ? -1 : 0); gameTicks++; - if (printboard) PrintBoard(); + if (printBoard) PrintBoard(); } return $"after {gameTicks} moves, the score is: {board[(-1, 0)]}"; |