From 1b510bf789803951ae24fa0d7476d151b4b43e2e Mon Sep 17 00:00:00 2001 From: Stefan Forstenlechner Date: Sun, 5 Dec 2021 15:17:17 +0100 Subject: [PATCH] Day3-5 --- Day2.cs | 2 +- Day3.cs | 68 ++++ Day4.cs | 64 ++++ Day5.cs | 63 ++++ Extension.cs | 12 + day3/input | 1000 ++++++++++++++++++++++++++++++++++++++++++++++++++ day4/input | 601 ++++++++++++++++++++++++++++++ day5/input | 500 +++++++++++++++++++++++++ 8 files changed, 2309 insertions(+), 1 deletion(-) create mode 100644 Day3.cs create mode 100644 Day4.cs create mode 100644 Day5.cs create mode 100644 Extension.cs create mode 100644 day3/input create mode 100644 day4/input create mode 100644 day5/input diff --git a/Day2.cs b/Day2.cs index 31c4a15..da253cf 100644 --- a/Day2.cs +++ b/Day2.cs @@ -1,4 +1,4 @@ -#define Day2 +// #define Day2 #if Day2 Position PartOne(Position p, Operation op) => op.op switch { "down" => new Position(p.f, p.d + op.x, p.aim), diff --git a/Day3.cs b/Day3.cs new file mode 100644 index 0000000..fac149a --- /dev/null +++ b/Day3.cs @@ -0,0 +1,68 @@ +// #define Day3 +#if Day3 +using AoC2021; + +var scans = File.ReadAllLines("day3/input").ToList(); +var significantBitsList = scans.First().Select(c => c == '0' ? new SignificantBits() { zeros = 1 } : new SignificantBits() { ones = 1 }).ToList(); +var indices = Enumerable.Range(0, significantBitsList.Count).ToList(); +scans.Skip(1).ForEachAsList(bits => + bits.ForEachIndex((b, i) => { + if (b == '0') { + significantBitsList[i].zeros++; + } + else { + significantBitsList[i].ones++; + } + })); + +var gammaStr = String.Join("", significantBitsList.Select(s => s.ones > s.zeros ? "1" : "0")); +var epsilonStr= String.Join("", significantBitsList.Select(s => s.ones < s.zeros ? "1" : "0")); + +var gamma = Convert.ToInt32(gammaStr, 2); +var epsilon = Convert.ToInt32(epsilonStr, 2); + +Console.WriteLine(gamma * epsilon); + +//Part2 +int PartTwo(Listscans, Func, HashSet, bool> check) { + var toCheck = Enumerable.Range(0, scans.Count).ToHashSet(); + int index = 0; + while (toCheck.Count() > 1) { + var ones = new HashSet(); + var zeros = new HashSet(); + + foreach (var o in toCheck) { + if (scans[o][index] == '1') { + ones.Add(o); + } + else { + zeros.Add(o); + } + } + + if (check(ones, zeros)) { + toCheck.ExceptWith(zeros); + } + else { + toCheck.ExceptWith(ones); + } + + index++; + } + + return toCheck.First(); +} + +int oxygenLine = PartTwo(scans, (ones, zeros) => ones.Count >= zeros.Count); +int scrubberLine = PartTwo(scans, (ones, zeros) => ones.Count < zeros.Count); + +int oxygen = Convert.ToInt32(scans[oxygenLine], 2); +int scrubber = Convert.ToInt32(scans[scrubberLine], 2); + +Console.WriteLine(oxygen * scrubber); //400894 + +class SignificantBits { + public int zeros { get; set; } + public int ones { get; set; } +} +#endif \ No newline at end of file diff --git a/Day4.cs b/Day4.cs new file mode 100644 index 0000000..f23621f --- /dev/null +++ b/Day4.cs @@ -0,0 +1,64 @@ +// #define Day4 +#if Day4 +using AoC2021; +var parts = File.ReadAllText("day4/input").Split("\n\n"); +var numbers = parts[0].Split(",").Select(int.Parse); + +var boards = parts.Skip(1).Select(ToBoard).ToList(); + +int numberOfBoards = boards.Count; +foreach (var num in numbers) { + var won = boards.Select((board, i) => new {bingo = CheckBoard(num, board), index = i}).Where(a => a.bingo).ToList(); + + // For PartTwo + if (won.Count > 0 && boards.Count == 1) { + int[,] winningBoard = boards[won.First().index]; + CalculateScore(winningBoard, num); + break; + } + if (won.Count > 0 && boards.Count == numberOfBoards) { + int[,] winningBoard = boards[won.First().index]; + CalculateScore(winningBoard, num); + } + + var wonIndices = won.Select(w => w.index).ToHashSet(); + boards = boards.Where((board, index) => !wonIndices.Contains(index)).ToList(); +} + +void CalculateScore(int[,] board, int lastNum) { + long sum = 0; + for (int row = 0; row < 5; row++) { + for (int col = 0; col < 5; col++) { + if (board[row, col] >= 0) { + sum += board[row, col]; + } + } + } + Console.WriteLine(sum * lastNum); +} + +bool CheckBoard(int num, int[,] board) { + bool bingo = false; + for (int row = 0; row < 5; row++) { + for (int col = 0; col < 5; col++) { + if (board[row, col] == num) { + board[row, col] *= -1; + bingo |= CheckRow(board, row) || CheckCol(board, col); + } + } + } + return bingo; +} + +bool CheckRow(int[,] board, int row) => Enumerable.Range(0, 5).All(col => board[row, col] < 0); +bool CheckCol(int[,] board, int col) => Enumerable.Range(0, 5).All(row => board[row, col] < 0); + +int[,] ToBoard(string s) { + int[,] board = new int[5,5]; + s.Split("\n") + .ForEachIndex((l, row) => l.Split(" ", StringSplitOptions.RemoveEmptyEntries) + .ForEachIndex((num, col)=> + board[row,col] = Int32.Parse(num))); + return board; +} +#endif \ No newline at end of file diff --git a/Day5.cs b/Day5.cs new file mode 100644 index 0000000..732c578 --- /dev/null +++ b/Day5.cs @@ -0,0 +1,63 @@ +#define Day5 +#define PartTwo +#if Day5 +using System.Text.RegularExpressions; +Regex regex = new Regex(@"^(?\d+),(?\d+) -> (?\d+),(?\d+)$"); + +var lines = File.ReadAllLines("day5/input") + .Select(l => { + var match = regex.Match(l); + return new Line( + new Point( + int.Parse(match.Groups["x1"].Value), + int.Parse(match.Groups["y1"].Value)), + new Point( + int.Parse(match.Groups["x2"].Value), + int.Parse(match.Groups["y2"].Value)) + ); + }).ToList(); + +var vents = new Dictionary(); +foreach (var line in lines) { + IEnumerable points; + if (line.start.x == line.end.x) { + points = Enumerable.Range(Math.Min(line.start.y, line.end.y), Math.Abs(line.start.y - line.end.y) + 1) + .Select(y => new Point(line.start.x, y)); + } else if (line.start.y == line.end.y) { + points = Enumerable.Range(Math.Min(line.start.x, line.end.x), Math.Abs(line.start.x - line.end.x) + 1) + .Select(x => new Point(x, line.start.y)); + } else { +#if PartTwo + Point smallerX; + Point largerX; + bool increasingY; + if (line.start.x < line.end.x) { + smallerX = line.start; + largerX = line.end; + } else { + smallerX = line.end; + largerX = line.start; + } + increasingY = smallerX.y < largerX.y; + points = Enumerable.Range(0, largerX.x - smallerX.x + 1) + .Select(i => new Point(smallerX.x + i, smallerX.y + (increasingY ? i : (i*(-1))))); +#else + points = new List(); +#endif + } + + foreach (var p in points) { + if (vents.ContainsKey(p)) { + vents[p] += 1; + } else { + vents[p] = 1; + } + } +} + +Console.WriteLine(vents.Count(v => v.Value > 1)); + + +record Line(Point start, Point end); +record Point(int x, int y); +#endif \ No newline at end of file diff --git a/Extension.cs b/Extension.cs new file mode 100644 index 0000000..2722829 --- /dev/null +++ b/Extension.cs @@ -0,0 +1,12 @@ +namespace AoC2021; + +public static class Extension { + public static void ForEachIndex(this IEnumerable enumerable, Action action) { + var l = enumerable.ToList(); + Enumerable.Range(0, l.Count).ToList().ForEach(i => action.Invoke(l[i], i)); + } + + public static void ForEachAsList(this IEnumerable enumerable, Action action) { + enumerable.ToList().ForEach(action); + } +} \ No newline at end of file diff --git a/day3/input b/day3/input new file mode 100644 index 0000000..15318ff --- /dev/null +++ b/day3/input @@ -0,0 +1,1000 @@ +111100101100 +101100110001 +100110100101 +001101100010 +010111011110 +000111001100 +001000011010 +110111000100 +101011101011 +111100111010 +111101011001 +011000010010 +101011001000 +010011001001 +110001001100 +001010010010 +010111001010 +000000001001 +001001010001 +011100010111 +001110111100 +001110010010 +000101100100 +010101110001 +110100100011 +100001001001 +001011101011 +010010001100 +011001011011 +001111000011 +000000110110 +110011101010 +100110110010 +100000111101 +100000001110 +010101001110 +010111101101 +110001001110 +100100111100 +000001110001 +101100011101 +100010000001 +110010110100 +000010110011 +101010111011 +011000000110 +010000100111 +111011011101 +111100000010 +011010111011 +010101011100 +100011110001 +110011010100 +010101100000 +101101110011 +000011000100 +111000000110 +101110111001 +100111111011 +110011100101 +101010000111 +000011111010 +000001100100 +111000101110 +101001011110 +100101101001 +110100001100 +001010001000 +110110101000 +100101110100 +101000001011 +011111101100 +000110011100 +001001010101 +101000110010 +111101011101 +110010010000 +001100110110 +001111011111 +010001111110 +001110010111 +100101000101 +010100111010 +100011001000 +010110011001 +001001111010 +101101001001 +111010101101 +101001110001 +001001001110 +100100101110 +110111110100 +110100011000 +011001010010 +010111001100 +000100110000 +110001000100 +111010011011 +011111011101 +011110111100 +001101111010 +100010011101 +111000110111 +110110001010 +110000101010 +001101000011 +011010011101 +111100100010 +001001110110 +001001001011 +010010110100 +010101010110 +101000001110 +011011010100 +010000011010 +010001011110 +111100110011 +111000100111 +100001010000 +010101001111 +101110010110 +110100001000 +000001110110 +000100001110 +000010100111 +010010101001 +110110011000 +111001110100 +001100011001 +110100001010 +110101001010 +111011000001 +100110111000 +011110111110 +101010111010 +100001010111 +010101010101 +010001110001 +110010000010 +000101001111 +111010100010 +100111011110 +000010111110 +011011010011 +101010110100 +100000010111 +100110111110 +010011010001 +000011101011 +111011010011 +100001110111 +000100001000 +010110100000 +001110100000 +010010100110 +000110111110 +110111100100 +001111011010 +101011010010 +010111010100 +011011000110 +101011111110 +001111100011 +101101100001 +010111100110 +010110000001 +110011011110 +110111001011 +110100101001 +010011011101 +110011010010 +100111001100 +010010101010 +010111110000 +010111000010 +001101111101 +011010110011 +001001100000 +100001101100 +011111000111 +111011110100 +100101010001 +101001111001 +001000101110 +010011100100 +111100011001 +111010111110 +111001010001 +110000001001 +110110000010 +000100100011 +010101111111 +100101001110 +100111111010 +000111111010 +010101111101 +010010100010 +101110100101 +100001000001 +000010001000 +110100110001 +110111100010 +100110010011 +101110011111 +111101110010 +001000001001 +010100101100 +100101110111 +010001100111 +010001010010 +100010100100 +001000000001 +011011110000 +010100011000 +110010101000 +100010001110 +000110001000 +101101010001 +001111010000 +111110111111 +100100110000 +000110010011 +001010101000 +011010011010 +111011110010 +001010011100 +111010100101 +011101111100 +010011000001 +001111101000 +111110010010 +100011100100 +010011010000 +011111000000 +110001010011 +101011001110 +101001111101 +000110001101 +010001000010 +011000000010 +011000100001 +011111011000 +111000001101 +011010001101 +000001000100 +101010010010 +111111100111 +010111111111 +001011110011 +100110000100 +000100010100 +010110000000 +110011100000 +010011101111 +110101111100 +000010001010 +101001010011 +010101101111 +111010011010 +001101101010 +001100101010 +100100001001 +101100110111 +000001001100 +011111011001 +110100101100 +110110110010 +011110001001 +100110100011 +010111111100 +110111111101 +010111000011 +101001101011 +010101101100 +011100000001 +001000101100 +110111011011 +001101001100 +111001111001 +010000111100 +010101111100 +000100010010 +100010001101 +110000111100 +110011010101 +111101100000 +001101011001 +010111110111 +010001100000 +101111000100 +101101111101 +001000001111 +101011110000 +111000000101 +101000000101 +111101111011 +101010111101 +101111000000 +010111011001 +011100101101 +100100001000 +101111110010 +000001000001 +000100100000 +100100011010 +011001100101 +011010001011 +010001111000 +001110101001 +100111001001 +000111001011 +100101110011 +111010000001 +010000011001 +101110001110 +111011110111 +110010011101 +100011001010 +001001100101 +011101001000 +100100001100 +000111111000 +101100011011 +111101010011 +111100010101 +101111100111 +011011100110 +101010110110 +111001000100 +011101000010 +101100101110 +100011001110 +001100000001 +101001001101 +001100101110 +111111010000 +001110001110 +000011110111 +100001000101 +011110001011 +001100101111 +100100110111 +110100010101 +011100110001 +101101111010 +111010011000 +101000100110 +100100001110 +111000011011 +100001001110 +111001000010 +100110100111 +011111101011 +101001110011 +010000000100 +111011111000 +011101110000 +110111110110 +000000100110 +001100110010 +101010110101 +000010101110 +000011011011 +101111011101 +000101011110 +101010000110 +010010111011 +000111010001 +011001011000 +111111010010 +110000101110 +001111101100 +001001001111 +001011010001 +010110110010 +101101100010 +111100110101 +101101001000 +110110000111 +101010011001 +011000100100 +010010011010 +100000100010 +111000110100 +011100000101 +010010110011 +000011001000 +101001100101 +010100111000 +101111111101 +011110101001 +100011110110 +101111001100 +100110111011 +110000000011 +100011010101 +101010001110 +010011000010 +000011000110 +010101110110 +001111101001 +101000001001 +110011110000 +000001001101 +000010110100 +001111101101 +010110000100 +010010001001 +111010110010 +110011111111 +111000000000 +101010110000 +010110100010 +100000000000 +010110010000 +110111001001 +010101011011 +001110011001 +011101111000 +110011011101 +100000110110 +100110011001 +001111100100 +010100110110 +000110111101 +111010101011 +101001100010 +011011010010 +000010010011 +101000011101 +101110010101 +000000110011 +100111111001 +011000011001 +000000000001 +101011110110 +111111011110 +010010111000 +010110100100 +101100100000 +000010111000 +111110010011 +010110110011 +111111110001 +011011100101 +110110101101 +001011110100 +110001111111 +101010010111 +000110011011 +001000011110 +101101101000 +111111010111 +101010111001 +010100000001 +101100101001 +000111110101 +101011111000 +100110011011 +010000000111 +100111011001 +110111010101 +011110011010 +001011011010 +111101100100 +011001101101 +100001111100 +000011011000 +100011011001 +101100011110 +011111011111 +001001010010 +110101110110 +000111000010 +000110001001 +111010110000 +001100101001 +110011101000 +101011110100 +110000001010 +011110111010 +101101101010 +110011101011 +011011010000 +110111101100 +100000001011 +001110110111 +000000100100 +111110011001 +001110011010 +011101101110 +100011110011 +101110101011 +001010101011 +010111011011 +100110110111 +100000101110 +010011100111 +000010011100 +011111011100 +011000111001 +111011101001 +000110110110 +100011100110 +101101110100 +101111000111 +111110110010 +000010010101 +111110100111 +110001011110 +110101110000 +100110101000 +011000111010 +011111110011 +010010010000 +001000110100 +100010100111 +100101100010 +011000100101 +000101111001 +101100001111 +110111000010 +010100011110 +000101100000 +101111011000 +000010100011 +000010000100 +010011001011 +100010110100 +000000101001 +000010110111 +110000100111 +010001101111 +010111000110 +110011011111 +010100010011 +011110001000 +001001101000 +111000110000 +011001111110 +101001011100 +101110000111 +111110010100 +001101011110 +010010111111 +011110000011 +011001110010 +001011110111 +000000001110 +111000011101 +110111101001 +111111001100 +100111010011 +111111101010 +110111111000 +001101100111 +111011011111 +000010111101 +100010011001 +010110100101 +011011001010 +000001101000 +001011110110 +000001111000 +100011001111 +110000100011 +100001010010 +110110000100 +110110010010 +101001101111 +111100000011 +110000111001 +100001011010 +110110011101 +101010001011 +010110011100 +111000101010 +001111111011 +010101101001 +100010111011 +100101010111 +011111100001 +001100100000 +111101101000 +000110000010 +010111100000 +001000110110 +100011101110 +010101011000 +110000000111 +100011100001 +100001100000 +000111010100 +110101011001 +101111100110 +011111101111 +000110000011 +000000100001 +001010000101 +111100100001 +111000010101 +011011011110 +101001001100 +100010110110 +100001101001 +101100001100 +100111000010 +011001000110 +011110110101 +000000100011 +011100000111 +101110111100 +010000010010 +110111110010 +100101001001 +010001010011 +000011100100 +000100100101 +010100010001 +100111101101 +101110000101 +110100101111 +001111101011 +010011101010 +110000110001 +000101101011 +111010001001 +011111010110 +001001111000 +111110110011 +111010011100 +010011011110 +100001010100 +010111010011 +011110001110 +111010100011 +110001000010 +100000100100 +001001101011 +001011111011 +110000010010 +000011001101 +001101001011 +011110010011 +100001110011 +011101100000 +110101001110 +001000111101 +001101110011 +001100101101 +011110001010 +111111011000 +101001101101 +110011010111 +101110001101 +111001101110 +011010011000 +101010101000 +010110000010 +100000110001 +011001000011 +011100010010 +010001001111 +001011000100 +101000101011 +111101010000 +100111100101 +001011101110 +010001000011 +111101000111 +110010011111 +011011001101 +010110101110 +100011100111 +101111111111 +111011011010 +000100111100 +000111011011 +101010001010 +111110000011 +101110011010 +011100001001 +100000011110 +011000100000 +011001010101 +001110110010 +101110101010 +010111110101 +101110101110 +101111010001 +101101001101 +001010101100 +011011001011 +011001110111 +111101100101 +101011100100 +011111111101 +110000111010 +010010011000 +011010110010 +010001000001 +100111101100 +011001111000 +101011010111 +001111100110 +111100001111 +001101010000 +000011001110 +110010011110 +111010100111 +110101001000 +001000100110 +101001011000 +010010101111 +011000001011 +000110001011 +000010000011 +001001111001 +011000111111 +101000010011 +111010011101 +101111101000 +111100010001 +111011000100 +100111100010 +111000011010 +010010000010 +111110110100 +010010111010 +110001010001 +101110111101 +010000001000 +000011111100 +111001001000 +101011001001 +111011011001 +010100001101 +010001001100 +010011001010 +000101010100 +010100001100 +001000011001 +100110101110 +011001111011 +010101100011 +111100000100 +100100101000 +110010001010 +000100101001 +000101100001 +000010011000 +101001111000 +001001000100 +011001001000 +010110010011 +100001010110 +010010010010 +010001011010 +101100111110 +101001010000 +110101110001 +100111001111 +010110110101 +101011010100 +011110011111 +010000010100 +111011000110 +011111001110 +010110111001 +000100010101 +100110001101 +001001001010 +000010010000 +010001111001 +001011011000 +010101011110 +110101101001 +111101011100 +010011110001 +101000110001 +111110110111 +001110001010 +101110111111 +000111011101 +010001110010 +101010010101 +001000011111 +010000010001 +101100010000 +110111101011 +001001011110 +100011011101 +110010100110 +111101111100 +111100011100 +000111110000 +000101010101 +011001011101 +000101110111 +001100011111 +110010011000 +010110111111 +111101000010 +111011010000 +111001110010 +010111000100 +111111100001 +000000010000 +001100001111 +101101111111 +101100000001 +011001100000 +100010110010 +111111111110 +000110010001 +001001111110 +111110111011 +110101001111 +010000000010 +000001101110 +100001011110 +111111100101 +101100100011 +100000010110 +100011000110 +000010010001 +100010111010 +111010111000 +011110110010 +000011000010 +010010011001 +010010000100 +110101111000 +010000001010 +100000011010 +001010001110 +000011010001 +100100111101 +111011111001 +010001010111 +010000100000 +000100101000 +101011011011 +111111010110 +111110000100 +100011101010 +100111011010 +010101001100 +011010000000 +111100100000 +011010111110 +011111001010 +111011011000 +001011001010 +111101101111 +100111100110 +011000000000 +000001011000 +100111011000 +001111100000 +000010101100 +110111001010 +011010100101 +001010010000 +110110011100 +010101110111 +111111110110 +011100110101 +101000010110 +100110110110 +101001101100 +111001011001 +000001010011 +000110100000 +111101101011 +101111101101 +100010111110 +010110011111 +000010000111 +000101101010 +011100000000 +001110011101 +011011110110 +111111101001 +111111010011 +110000110100 +100000010101 +001010000010 +111010101110 +001110010000 +100100010101 +100110001000 +111100011000 +001011100111 +100100110011 +001000001100 +000111001000 +100111111101 +100110010101 +101000001101 +111110001110 +001011100000 +000011111101 +010010001101 +000010011101 +001100111110 +000001100110 +110001101010 +001101010010 +110000110000 +100011001100 +001110011011 +110001110000 +010000011110 +100011111110 +101001101000 +001111011011 +010001011011 +111111010100 +001011001111 +001100010110 +001010111001 +110101010001 +001001111011 +010110001000 +110100101110 +100100100010 +010001101101 +100100000110 +110010110010 +011111000010 +000110010010 +001111110001 +110111101110 +111111000111 +011011011111 +011010101001 +011001011110 +010100110000 +010000101110 +101110100111 +100001010101 +101101010100 +000111101010 +111010000100 +100000110111 +001101110110 +011011100010 +010100111001 +000110100010 +110111101111 +100111000110 +101100110011 +010001000111 +110000101001 +100101011100 +001011111000 +100001110001 +010000011011 +001010111100 +000101101111 +011011111001 +110110101111 +100101011000 +011000110110 +100000011111 +110011100011 +010111001001 +000101010111 +000010100110 +101010110010 +000000001100 +111110001001 +011111011010 +011000111101 +110110001000 +110011001010 +100101101111 +100111101111 +100101100111 +110001001010 +010110110001 +001101101000 +101110001111 +000001001110 +010101110100 +001101011111 +100010100000 +101000011000 +010100100111 +110011100100 +110111110101 +000110001111 +000001011101 +001011101100 +111110000110 +100001010011 +000100000100 +001010011011 +110000110111 diff --git a/day4/input b/day4/input new file mode 100644 index 0000000..1bd0345 --- /dev/null +++ b/day4/input @@ -0,0 +1,601 @@ +91,17,64,45,8,13,47,19,52,68,63,76,82,44,28,56,37,2,78,48,32,58,72,53,9,85,77,89,36,22,49,86,51,99,6,92,80,87,7,25,31,66,84,4,98,67,46,61,59,79,0,3,38,27,23,95,20,35,14,30,26,33,42,93,12,57,11,54,50,75,90,41,88,96,40,81,24,94,18,39,70,34,21,55,5,29,71,83,1,60,74,69,10,62,43,73,97,65,15,16 + +83 40 67 98 4 +50 74 31 30 3 +75 64 79 61 5 +12 59 26 25 72 +36 33 18 54 10 + +68 56 28 57 12 +78 66 20 85 51 +35 23 7 99 44 +86 37 8 45 49 +40 77 32 6 88 + +75 15 20 79 8 +81 69 54 33 28 + 9 53 48 95 27 +65 84 40 71 36 +13 31 6 68 29 + +94 6 30 16 74 +91 47 66 31 90 +14 56 45 55 20 +58 70 27 46 73 +77 67 97 51 54 + +60 12 49 80 52 +15 27 85 82 48 +21 76 83 55 54 + 8 5 4 38 47 +73 2 86 44 99 + +64 60 6 38 37 + 3 69 21 24 11 +36 88 16 55 41 +78 7 81 95 91 +27 34 92 39 30 + +38 57 20 68 49 +21 18 69 97 60 +34 92 0 59 62 +10 43 93 87 64 +53 35 94 76 61 + +48 74 58 13 54 +57 18 37 92 78 +89 10 25 97 43 +38 99 64 6 66 +21 83 29 93 95 + +94 37 98 87 51 +50 65 77 83 95 +68 4 91 53 32 +56 26 15 2 80 +20 55 58 81 33 + +73 32 66 38 89 +18 79 40 78 55 +26 63 93 60 98 +42 65 96 47 57 +45 75 72 23 35 + +64 28 21 80 27 +93 58 71 67 11 +61 20 74 13 90 +76 35 46 94 40 +92 2 4 85 69 + +22 70 87 31 61 +74 78 58 4 90 +63 28 24 35 84 +59 8 89 88 47 +17 48 80 33 32 + +57 7 30 39 19 + 1 13 41 15 50 +44 72 2 5 70 +34 93 60 80 69 +49 14 25 10 33 + +45 41 77 89 27 +68 99 11 32 95 +15 4 72 98 52 +53 28 14 75 44 +57 9 62 92 69 + + 7 21 2 73 40 +52 60 57 53 65 +63 86 36 82 44 +14 28 39 12 80 +66 64 91 50 51 + +82 5 38 41 95 +70 52 11 21 51 +81 20 0 14 83 +57 36 60 59 42 +77 13 85 32 63 + +91 40 42 3 50 +22 24 81 31 93 + 9 79 82 43 89 + 6 77 76 26 37 +29 8 53 23 4 + + 7 78 32 44 74 +29 3 84 38 79 +58 41 87 88 30 +68 19 72 81 47 +15 63 52 6 26 + +20 41 92 84 25 + 9 4 96 85 66 +49 15 50 89 19 +48 45 82 86 60 +29 18 53 47 16 + +75 39 45 31 73 +91 86 69 94 66 +28 61 17 20 0 +88 21 89 41 37 +35 2 10 18 82 + +80 23 4 73 93 +89 8 20 12 45 +74 99 58 90 67 +50 85 35 88 55 +18 65 42 47 48 + +16 38 65 64 25 +20 74 37 15 82 +23 76 97 48 53 +60 93 85 1 35 +77 10 59 2 58 + +11 9 57 40 46 +35 88 29 52 17 +30 2 7 6 0 +13 63 44 68 59 +83 98 5 50 65 + +82 40 2 14 50 + 7 31 91 19 11 +51 42 56 44 6 +66 74 22 95 64 +63 1 17 86 24 + +18 19 66 63 80 +65 23 74 22 85 + 5 7 37 75 51 +38 58 68 83 32 +40 29 31 15 43 + +37 54 13 77 31 +57 96 28 87 95 +10 11 19 49 45 +12 21 79 56 24 +34 64 84 69 17 + + 6 33 48 61 0 +85 34 7 84 37 +25 46 59 76 82 +18 62 20 44 2 +12 78 60 56 99 + +95 6 1 39 2 +46 34 28 64 22 +48 23 89 56 55 +44 81 82 43 74 +65 31 94 49 91 + +69 42 27 52 54 +79 60 62 83 38 + 5 21 56 48 99 +51 40 15 7 24 +92 10 66 64 88 + +99 18 22 52 81 +21 42 13 71 59 +91 38 68 10 25 +54 19 76 60 24 +41 92 2 3 64 + +76 5 25 55 84 +70 15 89 67 68 +34 86 11 4 6 + 9 23 43 41 52 +58 10 88 38 0 + +83 91 85 81 86 + 5 10 89 6 48 +45 77 2 9 90 +74 8 57 75 67 +73 30 49 96 15 + +66 13 82 89 20 + 5 67 94 64 0 +58 73 4 62 49 +59 28 75 79 44 +54 71 57 33 36 + +23 36 29 80 30 +51 91 77 2 84 +78 90 15 21 75 +28 93 22 55 16 +67 50 58 60 68 + +82 80 37 91 7 +54 81 85 25 24 +33 36 89 30 56 +83 95 99 48 10 + 4 44 1 55 79 + + 9 13 53 20 26 + 7 31 49 84 58 +51 91 90 68 55 +19 38 23 81 33 +34 99 85 37 54 + +44 66 81 78 15 +31 14 48 65 0 +26 10 20 4 41 +77 68 95 34 73 +74 12 36 3 60 + + 6 24 78 58 36 +30 51 75 13 40 +17 1 3 42 59 +64 20 4 18 79 +37 61 84 63 7 + +41 83 1 75 18 +14 56 67 32 22 +69 80 46 84 49 +72 21 9 10 35 + 4 37 28 40 12 + +56 80 47 17 70 +12 22 77 81 11 +61 30 58 60 71 +52 0 25 86 65 +59 28 79 20 26 + +70 75 81 18 67 + 2 85 73 8 17 +74 3 34 92 30 +51 72 84 56 45 +37 90 31 97 78 + + 2 73 71 43 69 + 6 54 89 57 93 +81 0 39 25 90 +79 27 92 29 15 +45 76 87 11 91 + +98 35 51 49 34 +23 12 77 27 82 + 6 89 0 76 46 +81 48 99 45 90 +10 75 17 96 29 + +45 19 82 93 0 +84 24 73 2 98 +94 46 7 48 56 +80 34 5 18 31 +58 33 83 29 55 + +66 81 99 54 63 +21 94 72 77 64 +58 52 85 46 68 + 5 6 78 42 4 +76 38 51 24 33 + +93 26 5 59 67 +13 84 76 4 69 + 0 17 30 83 48 + 8 53 32 14 92 +94 18 66 46 61 + +28 48 38 6 25 +70 39 71 77 22 +66 94 18 43 36 +30 67 57 9 90 +15 34 50 3 86 + +11 90 99 92 87 +78 79 56 21 50 +19 18 22 20 30 +95 41 59 85 26 +66 58 46 38 57 + +49 92 2 93 77 +46 89 44 57 19 +53 8 32 18 88 +54 95 59 70 10 +72 84 86 42 81 + +44 78 25 4 57 +72 7 42 94 8 +61 79 11 29 59 +22 82 6 90 12 +98 77 5 68 50 + +48 41 64 15 57 +76 7 52 53 93 +70 84 94 38 35 +47 18 13 51 21 +77 62 63 3 65 + +31 33 48 79 69 +30 9 83 53 50 +60 94 36 2 28 +59 19 10 5 40 +26 41 72 14 96 + + 0 16 49 75 17 +28 20 21 99 94 +15 8 4 68 71 +23 53 76 19 74 +79 61 72 70 52 + +70 89 12 80 76 +14 18 16 4 91 +34 64 43 51 71 + 6 78 30 5 13 +57 42 15 73 24 + +64 99 72 41 54 +21 29 25 40 9 +92 48 82 70 98 +65 62 8 78 27 +71 86 36 34 23 + +23 19 72 77 63 +85 0 61 40 14 +69 76 18 56 95 +68 66 28 79 13 +83 84 45 89 2 + +18 40 28 70 37 +80 30 67 96 34 +77 25 97 32 11 +48 46 89 14 29 + 2 8 95 0 12 + + 0 26 1 9 30 +17 2 78 18 65 +84 7 61 93 81 +80 44 82 23 99 +72 95 19 60 28 + +37 39 0 20 21 +91 36 93 16 22 +53 95 26 72 25 +97 33 60 55 65 +79 56 73 29 75 + +22 58 99 57 28 + 2 56 93 91 18 +44 64 92 85 46 +70 47 89 27 54 +83 5 48 97 72 + +72 1 73 68 36 +31 8 14 41 35 +23 96 7 92 83 +56 39 77 93 91 +20 28 67 10 11 + +62 27 17 54 0 +35 60 73 20 5 +23 58 46 99 75 +19 53 79 70 88 +31 85 77 1 32 + +22 90 81 42 55 +70 78 86 19 94 + 1 43 15 33 51 +84 96 87 58 6 +49 64 4 59 23 + +82 63 58 75 89 +35 37 52 80 24 +93 50 76 79 1 +86 59 30 92 7 +42 11 55 70 22 + +83 3 71 28 95 +70 23 68 57 1 +60 6 19 63 32 +64 55 97 81 49 +91 80 88 5 35 + +23 68 51 62 20 +70 52 98 34 41 +12 21 85 43 84 +69 49 36 28 0 +76 30 58 91 60 + +30 72 6 41 43 +67 79 46 96 99 +58 71 39 87 69 +17 18 11 57 25 +45 75 16 33 42 + +22 75 24 74 90 +34 70 44 86 23 +29 59 68 4 48 +88 45 92 27 49 +47 77 26 99 82 + +42 29 21 74 33 +64 37 38 50 84 +46 44 41 1 67 +53 66 96 68 59 + 6 94 11 31 99 + +24 32 71 87 57 +42 26 55 80 99 +82 27 16 19 92 +96 48 62 31 61 +60 89 95 18 6 + +99 33 55 71 29 +75 37 23 27 98 + 2 78 90 18 35 +59 10 56 0 6 +12 19 76 70 96 + +33 37 23 61 80 + 6 13 68 51 76 +92 25 3 95 55 +99 63 17 52 30 +11 94 42 5 98 + +77 37 25 14 73 +95 90 10 19 72 +78 30 44 47 91 + 3 60 32 5 66 +21 55 87 98 6 + + 6 60 82 90 98 +21 70 54 66 27 +37 64 55 10 14 +57 25 84 50 20 +42 59 85 3 73 + +74 84 92 10 51 +57 82 93 90 44 +41 43 76 48 59 +79 49 69 16 72 +37 29 63 15 68 + +37 90 97 86 18 + 2 83 30 53 92 +45 35 78 47 40 +67 61 17 14 84 +32 33 81 10 11 + +46 48 39 3 50 +83 29 91 73 67 +25 43 89 71 36 +63 62 78 95 18 +82 34 23 85 11 + +19 68 80 50 13 + 1 45 51 27 39 +98 26 24 46 49 +14 92 63 88 66 +15 44 84 47 94 + +19 39 93 43 86 +91 58 3 69 41 +18 36 95 52 83 +12 6 22 48 0 +25 70 40 88 73 + +95 11 94 13 14 +64 87 57 98 49 +47 88 84 61 2 +46 21 15 74 59 +82 73 78 3 51 + +18 72 29 7 36 +96 67 81 78 23 +43 40 44 47 98 +41 26 15 90 71 +42 62 93 70 2 + +17 8 59 25 33 +81 47 55 99 48 +86 14 71 54 50 +90 11 23 18 0 +97 65 82 68 42 + +50 54 68 90 83 +10 28 77 55 61 +38 60 52 80 44 +40 81 14 24 87 +51 82 42 30 8 + +54 5 64 22 60 +70 19 83 11 45 +46 39 2 56 6 +61 8 28 20 94 + 0 4 81 34 84 + +96 21 48 89 15 +91 40 9 97 65 +26 58 10 18 78 +98 79 29 80 28 +17 59 43 84 99 + +67 73 21 9 31 +68 37 26 65 84 +63 24 42 27 40 +61 25 30 34 35 +53 23 48 81 29 + +24 34 5 67 62 +89 85 68 37 78 +42 87 13 49 41 +74 55 70 86 76 +73 94 97 63 48 + +88 24 6 75 30 +77 64 16 34 93 +36 76 0 40 81 +67 14 89 84 95 +32 19 18 66 9 + +97 71 65 30 69 +41 21 40 31 33 +50 55 35 52 53 + 4 51 13 81 72 +12 83 14 64 18 + +97 7 8 74 10 + 3 92 31 25 41 +20 32 45 72 55 + 1 43 49 98 27 +99 54 57 13 76 + +86 81 67 6 97 +34 18 96 43 56 +59 75 17 26 9 + 0 38 60 94 14 + 4 55 64 61 88 + +37 15 48 43 66 +45 54 90 81 47 +63 64 28 82 93 +34 52 6 99 61 +49 12 71 23 46 + +90 87 89 97 1 +48 0 82 60 43 +55 30 68 25 83 +78 3 23 16 66 +98 2 19 63 17 + +89 52 49 14 38 +69 12 50 17 90 +58 53 26 20 29 +39 65 43 7 5 +84 68 94 85 25 + +95 25 42 36 47 +50 54 83 84 37 +94 70 99 79 18 +57 8 69 52 31 +66 20 35 71 38 + +81 18 47 68 15 + 3 50 16 83 37 +34 31 9 57 76 +74 95 40 63 48 +13 28 20 43 66 + +52 21 62 41 67 +22 56 36 18 23 +59 44 27 73 3 +72 50 19 33 76 +45 55 70 46 92 + +72 96 50 83 68 +31 78 59 57 93 +43 58 17 52 35 +87 34 91 76 0 +54 75 53 25 62 + +21 53 68 5 80 +47 67 6 81 9 +64 46 35 26 39 +50 24 84 45 71 +66 15 83 3 97 + +22 97 31 90 63 +21 51 38 74 78 +10 64 92 82 1 +70 12 75 16 14 +68 50 35 73 26 diff --git a/day5/input b/day5/input new file mode 100644 index 0000000..884067a --- /dev/null +++ b/day5/input @@ -0,0 +1,500 @@ +88,177 -> 566,655 +346,264 -> 872,264 +409,631 -> 506,534 +300,216 -> 300,507 +80,370 -> 193,483 +85,283 -> 85,483 +589,528 -> 968,528 +936,83 -> 936,909 +21,41 -> 907,927 +868,624 -> 868,490 +954,972 -> 51,69 +95,223 -> 851,979 +681,222 -> 681,32 +596,557 -> 384,557 +830,945 -> 830,210 +146,17 -> 582,17 +923,864 -> 923,854 +698,289 -> 893,94 +521,860 -> 521,658 +602,699 -> 602,626 +115,537 -> 12,434 +872,264 -> 239,897 +820,674 -> 820,752 +885,292 -> 519,658 +88,193 -> 88,618 +371,681 -> 556,681 +222,894 -> 741,894 +81,790 -> 277,790 +973,328 -> 973,42 +517,548 -> 491,522 +75,417 -> 260,417 +920,334 -> 920,416 +923,110 -> 44,989 +736,333 -> 714,333 +697,850 -> 345,850 +404,746 -> 770,380 +156,166 -> 156,857 +579,571 -> 796,788 +94,929 -> 277,746 +929,313 -> 929,633 +337,951 -> 337,651 +751,841 -> 119,209 +648,705 -> 775,578 +496,362 -> 84,362 +22,19 -> 981,978 +463,111 -> 877,111 +857,378 -> 299,936 +973,527 -> 967,527 +951,266 -> 96,266 +902,624 -> 925,647 +972,380 -> 167,380 +161,622 -> 161,733 +673,240 -> 763,330 +58,767 -> 776,767 +124,948 -> 721,351 +834,777 -> 304,247 +371,78 -> 237,212 +183,652 -> 183,422 +632,228 -> 632,445 +235,629 -> 151,629 +588,225 -> 588,388 +454,954 -> 454,513 +58,550 -> 58,359 +622,857 -> 95,857 +45,315 -> 672,942 +505,574 -> 670,409 +354,176 -> 276,176 +43,75 -> 948,980 +36,210 -> 36,93 +847,84 -> 268,84 +834,935 -> 798,971 +190,709 -> 190,407 +735,216 -> 478,473 +227,492 -> 59,492 +584,77 -> 584,789 +501,681 -> 299,681 +275,598 -> 932,598 +646,338 -> 646,484 +676,366 -> 543,366 +746,840 -> 305,399 +48,284 -> 48,336 +146,892 -> 299,739 +338,724 -> 338,969 +959,245 -> 384,245 +890,359 -> 554,23 +636,580 -> 181,580 +881,770 -> 244,133 +191,43 -> 950,802 +317,290 -> 317,671 +884,452 -> 884,981 +798,127 -> 798,892 +160,387 -> 160,173 +76,925 -> 977,24 +123,475 -> 593,475 +122,626 -> 472,976 +549,683 -> 549,456 +140,87 -> 475,87 +815,461 -> 815,156 +49,866 -> 866,49 +934,580 -> 880,580 +622,100 -> 622,402 +247,125 -> 35,337 +551,490 -> 551,115 +139,247 -> 713,247 +907,923 -> 907,788 +78,184 -> 111,184 +593,278 -> 593,385 +354,925 -> 916,363 +104,535 -> 104,958 +15,973 -> 967,21 +735,653 -> 609,653 +460,81 -> 80,81 +797,781 -> 942,781 +178,847 -> 968,57 +916,651 -> 916,347 +695,74 -> 51,718 +371,239 -> 479,239 +743,453 -> 377,819 +725,261 -> 633,169 +598,724 -> 598,339 +519,432 -> 455,496 +368,510 -> 10,868 +179,810 -> 909,80 +521,58 -> 521,438 +453,728 -> 453,149 +54,980 -> 961,73 +307,592 -> 307,116 +837,367 -> 837,101 +796,309 -> 796,125 +281,732 -> 743,732 +367,905 -> 367,653 +151,253 -> 100,253 +486,380 -> 486,653 +483,335 -> 401,253 +915,971 -> 218,274 +844,126 -> 901,183 +661,136 -> 875,136 +953,636 -> 953,355 +216,895 -> 830,895 +781,153 -> 214,720 +591,534 -> 923,866 +36,504 -> 558,504 +239,822 -> 57,822 +363,451 -> 363,482 +39,422 -> 332,422 +103,797 -> 103,663 +525,243 -> 525,177 +330,916 -> 528,916 +594,136 -> 343,387 +817,457 -> 817,306 +573,788 -> 525,788 +796,162 -> 574,162 +911,260 -> 143,260 +271,741 -> 18,741 +304,833 -> 980,157 +166,261 -> 848,943 +958,941 -> 41,24 +551,834 -> 551,213 +531,203 -> 356,28 +655,676 -> 481,676 +622,86 -> 10,698 +160,858 -> 823,858 +145,86 -> 857,798 +37,315 -> 359,315 +316,578 -> 316,220 +405,410 -> 405,501 +649,715 -> 903,461 +965,772 -> 965,578 +722,111 -> 330,111 +204,426 -> 204,674 +234,591 -> 234,80 +151,684 -> 453,382 +523,492 -> 523,599 +694,569 -> 637,626 +961,80 -> 85,956 +278,986 -> 163,986 +771,766 -> 23,18 +278,834 -> 278,81 +605,151 -> 605,312 +594,593 -> 16,593 +307,512 -> 307,306 +69,106 -> 69,270 +899,517 -> 899,90 +960,988 -> 11,39 +304,398 -> 293,398 +204,412 -> 572,780 +142,400 -> 142,16 +686,353 -> 556,223 +554,886 -> 946,886 +591,451 -> 591,283 +485,119 -> 416,119 +320,319 -> 797,319 +647,534 -> 152,39 +898,78 -> 35,78 +168,436 -> 710,436 +966,959 -> 23,16 +913,650 -> 879,650 +397,252 -> 459,314 +298,821 -> 454,821 +399,846 -> 443,846 +57,121 -> 683,747 +727,694 -> 85,52 +475,492 -> 475,710 +33,818 -> 550,301 +980,76 -> 81,975 +928,921 -> 928,476 +731,719 -> 731,494 +614,334 -> 976,334 +716,932 -> 100,316 +525,984 -> 909,600 +967,663 -> 967,460 +740,459 -> 740,954 +454,757 -> 305,906 +259,594 -> 344,509 +77,885 -> 233,885 +606,680 -> 232,680 +212,181 -> 82,181 +70,554 -> 70,635 +443,831 -> 164,831 +280,538 -> 280,504 +297,328 -> 297,348 +982,855 -> 920,793 +789,374 -> 747,332 +12,14 -> 975,977 +978,523 -> 978,552 +226,600 -> 798,600 +335,566 -> 881,20 +431,93 -> 431,725 +61,223 -> 61,912 +967,24 -> 16,975 +858,695 -> 310,147 +448,295 -> 866,295 +436,273 -> 641,273 +446,20 -> 654,20 +36,841 -> 36,287 +814,854 -> 839,829 +567,952 -> 674,952 +31,627 -> 31,852 +410,589 -> 322,677 +812,686 -> 467,341 +493,403 -> 787,403 +694,857 -> 927,857 +795,986 -> 795,225 +117,477 -> 117,619 +808,196 -> 808,587 +884,541 -> 894,531 +527,641 -> 527,337 +144,394 -> 346,394 +99,348 -> 598,348 +67,918 -> 944,41 +219,76 -> 420,76 +370,847 -> 416,847 +16,156 -> 743,156 +896,131 -> 896,402 +405,561 -> 405,773 +910,329 -> 24,329 +293,389 -> 792,888 +159,805 -> 159,769 +905,974 -> 905,767 +187,849 -> 927,109 +779,315 -> 779,823 +942,763 -> 299,763 +33,122 -> 120,122 +985,951 -> 61,27 +739,650 -> 332,650 +558,296 -> 100,754 +481,301 -> 454,301 +69,582 -> 69,874 +40,566 -> 69,566 +589,619 -> 589,336 +446,701 -> 76,701 +949,308 -> 949,339 +931,65 -> 931,571 +31,851 -> 31,317 +70,985 -> 961,94 +570,467 -> 570,666 +380,644 -> 380,739 +763,829 -> 749,829 +410,545 -> 780,915 +460,579 -> 460,88 +331,643 -> 560,872 +249,492 -> 844,492 +714,388 -> 714,61 +441,470 -> 537,470 +174,796 -> 256,796 +589,710 -> 369,490 +791,943 -> 425,943 +584,578 -> 114,578 +237,427 -> 851,427 +874,575 -> 235,575 +356,108 -> 204,260 +880,816 -> 754,816 +646,382 -> 646,156 +757,454 -> 337,34 +486,633 -> 694,633 +718,450 -> 647,450 +353,583 -> 605,331 +761,770 -> 563,770 +178,720 -> 928,720 +162,733 -> 717,178 +539,968 -> 207,968 +161,38 -> 161,403 +602,922 -> 496,816 +483,291 -> 483,743 +252,480 -> 543,480 +498,493 -> 498,132 +89,146 -> 562,619 +236,883 -> 555,564 +379,865 -> 389,865 +486,791 -> 688,791 +672,387 -> 672,660 +867,131 -> 838,131 +570,848 -> 850,848 +526,560 -> 966,560 +15,11 -> 983,979 +933,979 -> 888,979 +241,96 -> 985,840 +812,816 -> 812,524 +130,255 -> 130,140 +248,927 -> 628,927 +99,841 -> 874,66 +501,938 -> 77,938 +647,527 -> 983,527 +601,25 -> 601,577 +459,196 -> 662,196 +205,551 -> 639,117 +449,215 -> 147,215 +162,529 -> 624,529 +297,203 -> 297,11 +669,636 -> 948,357 +203,286 -> 53,436 +602,836 -> 602,850 +747,802 -> 747,685 +127,592 -> 448,913 +443,689 -> 826,689 +739,198 -> 739,169 +211,264 -> 211,541 +866,302 -> 45,302 +782,787 -> 86,91 +560,285 -> 560,254 +828,131 -> 645,131 +95,953 -> 95,17 +866,338 -> 866,165 +699,981 -> 357,981 +720,721 -> 111,112 +504,179 -> 77,179 +505,490 -> 732,717 +923,930 -> 22,29 +261,988 -> 518,988 +619,512 -> 475,512 +968,301 -> 714,555 +821,483 -> 821,50 +566,608 -> 566,119 +395,355 -> 519,355 +933,535 -> 618,535 +344,925 -> 344,596 +959,107 -> 959,96 +86,177 -> 686,777 +912,153 -> 910,155 +231,12 -> 977,758 +775,774 -> 775,486 +209,29 -> 209,338 +936,228 -> 970,262 +489,758 -> 309,758 +680,493 -> 222,493 +39,477 -> 416,854 +137,149 -> 838,850 +879,801 -> 879,710 +968,797 -> 765,797 +475,206 -> 679,206 +905,447 -> 440,912 +866,42 -> 243,665 +14,234 -> 437,234 +944,703 -> 280,39 +191,987 -> 191,357 +569,394 -> 898,394 +730,965 -> 390,965 +590,544 -> 893,544 +776,860 -> 711,795 +912,59 -> 58,913 +582,791 -> 45,254 +146,881 -> 915,881 +65,579 -> 65,26 +172,809 -> 172,714 +723,14 -> 308,429 +161,270 -> 804,270 +141,371 -> 522,371 +810,598 -> 869,598 +616,99 -> 929,412 +85,771 -> 85,88 +607,70 -> 272,70 +579,509 -> 615,473 +757,45 -> 176,45 +801,789 -> 801,527 +64,546 -> 64,963 +889,219 -> 727,219 +199,740 -> 199,360 +468,315 -> 317,164 +481,213 -> 481,342 +105,694 -> 105,915 +165,908 -> 983,90 +226,524 -> 886,524 +891,358 -> 891,812 +94,29 -> 728,663 +289,789 -> 289,954 +842,923 -> 204,285 +213,45 -> 784,45 +446,529 -> 856,939 +535,450 -> 941,450 +22,984 -> 985,21 +76,247 -> 76,760 +400,772 -> 955,772 +437,101 -> 437,105 +962,892 -> 499,892 +744,75 -> 171,648 +943,389 -> 348,389 +908,943 -> 14,49 +226,427 -> 226,65 +902,86 -> 902,655 +615,541 -> 615,825 +178,842 -> 829,842 +13,774 -> 659,128 +746,174 -> 807,174 +308,64 -> 248,64 +452,384 -> 452,403 +852,516 -> 692,356 +224,878 -> 224,642 +134,17 -> 809,692 +488,872 -> 488,906 +140,823 -> 883,823 +602,934 -> 487,934 +307,31 -> 307,102 +272,568 -> 414,568 +593,425 -> 110,425 +542,184 -> 542,381 +695,425 -> 691,425 +962,982 -> 50,70 +32,252 -> 32,425 +980,961 -> 35,16 +689,626 -> 689,458 +653,440 -> 867,440 +229,290 -> 229,573 +957,545 -> 957,343 +431,481 -> 108,481 +839,433 -> 126,433 +47,806 -> 598,255 +696,447 -> 283,447 +164,150 -> 164,836 +394,248 -> 394,100 +641,790 -> 300,790 +537,592 -> 537,272 +861,698 -> 861,307 +226,965 -> 365,965 +815,958 -> 815,38 +732,289 -> 732,808 +936,527 -> 936,741 +228,155 -> 484,155 +125,503 -> 125,262 +951,882 -> 951,182 +170,244 -> 170,241 +413,133 -> 942,662 +396,179 -> 396,261 +522,105 -> 522,729 +958,171 -> 643,171 +333,823 -> 921,235 +639,887 -> 656,904 +411,254 -> 243,254 +987,771 -> 975,771 +982,433 -> 982,456 +537,19 -> 537,784 +731,370 -> 731,872 +917,950 -> 32,65 +369,332 -> 981,944 +387,448 -> 102,733 +325,269 -> 833,269 +256,830 -> 256,428 +566,227 -> 945,606 +219,737 -> 916,40 +404,842 -> 404,155 +77,281 -> 586,790 +980,254 -> 980,675 +312,417 -> 90,417 +937,584 -> 288,584 +14,595 -> 609,595 +788,579 -> 908,699 +576,625 -> 576,430 +250,752 -> 366,868 +949,924 -> 67,42 +854,418 -> 854,294 +215,774 -> 287,774 +651,511 -> 651,523 +974,16 -> 518,472 +98,27 -> 679,27 +727,896 -> 20,896 +953,557 -> 845,449 +219,60 -> 755,596 +34,868 -> 358,868 +900,908 -> 61,69 +56,108 -> 391,108 +661,661 -> 613,661