about summary refs log tree commit diff
path: root/aoc2019/Day11.cs
diff options
context:
space:
mode:
Diffstat (limited to 'aoc2019/Day11.cs')
-rw-r--r--aoc2019/Day11.cs14
1 files changed, 7 insertions, 7 deletions
diff --git a/aoc2019/Day11.cs b/aoc2019/Day11.cs
index 31a5d88..2a299cb 100644
--- a/aoc2019/Day11.cs
+++ b/aoc2019/Day11.cs
@@ -85,15 +85,15 @@ namespace aoc2019
         public override string Part2()
         {
             var map = PaintShip(1);
-            var minX = (int) map.Keys.Select(x => x.x).Min();
-            var maxX = (int) map.Keys.Select(x => x.x).Max();
-            var minY = (int) map.Keys.Select(x => x.y).Min();
-            var maxY = (int) map.Keys.Select(x => x.y).Max();
+            var minX = (int) map.Keys.Select(i => i.x).Min();
+            var maxX = (int) map.Keys.Select(i => i.x).Max();
+            var minY = (int) map.Keys.Select(i => i.y).Min();
+            var maxY = (int) map.Keys.Select(i => i.y).Max();
 
-            return Enumerable.Range(minY, maxY - minY + 1)
-                .Select(y =>
+            return "\n" + Enumerable.Range(minY, maxY - minY + 1)
+                .Select(j =>
                     Enumerable.Range(minX, maxX - minX + 1)
-                        .Select(x => map.GetValueOrDefault((x, y)) == 0 ? ' ' : '#')
+                        .Select(i => map.GetValueOrDefault((x: i, y: j)) == 0 ? ' ' : '#')
                         .ToDelimitedString()
                 )
                 .Reverse()