From 67be7b5b4c39780bddb1f2ec6f7c1cbdb892ae09 Mon Sep 17 00:00:00 2001 From: Luke Hubmayer-Werner Date: Tue, 4 Dec 2018 15:57:16 +1030 Subject: [PATCH] Added 2018 day4, 2015 some days --- 2015/day12.py | 20 + 2015/day13-input | 56 +++ 2015/day13.py | 31 ++ 2015/day14-input | 9 + 2015/day14.py | 28 ++ 2015/day15-input | 4 + 2015/day17-input | 20 + 2015/day17.py | 19 + 2015/day20.py | 8 + 2018/day4-input | 1131 ++++++++++++++++++++++++++++++++++++++++++++++ 2018/day4.py | 53 +++ 11 files changed, 1379 insertions(+) create mode 100644 2015/day13-input create mode 100644 2015/day13.py create mode 100644 2015/day14-input create mode 100644 2015/day14.py create mode 100644 2015/day15-input create mode 100644 2015/day17-input create mode 100644 2015/day17.py create mode 100644 2015/day20.py create mode 100644 2018/day4-input create mode 100644 2018/day4.py diff --git a/2015/day12.py b/2015/day12.py index b30b4de..452992f 100644 --- a/2015/day12.py +++ b/2015/day12.py @@ -13,3 +13,23 @@ def parse_float(val): with open('day12-input', 'r') as file: data = json.load(file, parse_float=parse_float, parse_int=parse_int) print(number_sum) # Part 1 + +number_sum_2 = 0.0 +def count(obj): + if isinstance(obj, dict): + if 'red' in obj.values() or 'red' in obj.keys(): + return + for i in obj.keys(): + count(i) + for i in obj.values(): + count(i) + elif isinstance(obj, list): + for i in obj: + count(i) + elif not isinstance(obj, str): + global number_sum_2 + number_sum_2 += obj + +for d in data: + count(d) +print(number_sum_2) # Part 2 diff --git a/2015/day13-input b/2015/day13-input new file mode 100644 index 0000000..83755b0 --- /dev/null +++ b/2015/day13-input @@ -0,0 +1,56 @@ +Alice would lose 57 happiness units by sitting next to Bob. +Alice would lose 62 happiness units by sitting next to Carol. +Alice would lose 75 happiness units by sitting next to David. +Alice would gain 71 happiness units by sitting next to Eric. +Alice would lose 22 happiness units by sitting next to Frank. +Alice would lose 23 happiness units by sitting next to George. +Alice would lose 76 happiness units by sitting next to Mallory. +Bob would lose 14 happiness units by sitting next to Alice. +Bob would gain 48 happiness units by sitting next to Carol. +Bob would gain 89 happiness units by sitting next to David. +Bob would gain 86 happiness units by sitting next to Eric. +Bob would lose 2 happiness units by sitting next to Frank. +Bob would gain 27 happiness units by sitting next to George. +Bob would gain 19 happiness units by sitting next to Mallory. +Carol would gain 37 happiness units by sitting next to Alice. +Carol would gain 45 happiness units by sitting next to Bob. +Carol would gain 24 happiness units by sitting next to David. +Carol would gain 5 happiness units by sitting next to Eric. +Carol would lose 68 happiness units by sitting next to Frank. +Carol would lose 25 happiness units by sitting next to George. +Carol would gain 30 happiness units by sitting next to Mallory. +David would lose 51 happiness units by sitting next to Alice. +David would gain 34 happiness units by sitting next to Bob. +David would gain 99 happiness units by sitting next to Carol. +David would gain 91 happiness units by sitting next to Eric. +David would lose 38 happiness units by sitting next to Frank. +David would gain 60 happiness units by sitting next to George. +David would lose 63 happiness units by sitting next to Mallory. +Eric would gain 23 happiness units by sitting next to Alice. +Eric would lose 69 happiness units by sitting next to Bob. +Eric would lose 33 happiness units by sitting next to Carol. +Eric would lose 47 happiness units by sitting next to David. +Eric would gain 75 happiness units by sitting next to Frank. +Eric would gain 82 happiness units by sitting next to George. +Eric would gain 13 happiness units by sitting next to Mallory. +Frank would gain 77 happiness units by sitting next to Alice. +Frank would gain 27 happiness units by sitting next to Bob. +Frank would lose 87 happiness units by sitting next to Carol. +Frank would gain 74 happiness units by sitting next to David. +Frank would lose 41 happiness units by sitting next to Eric. +Frank would lose 99 happiness units by sitting next to George. +Frank would gain 26 happiness units by sitting next to Mallory. +George would lose 63 happiness units by sitting next to Alice. +George would lose 51 happiness units by sitting next to Bob. +George would lose 60 happiness units by sitting next to Carol. +George would gain 30 happiness units by sitting next to David. +George would lose 100 happiness units by sitting next to Eric. +George would lose 63 happiness units by sitting next to Frank. +George would gain 57 happiness units by sitting next to Mallory. +Mallory would lose 71 happiness units by sitting next to Alice. +Mallory would lose 28 happiness units by sitting next to Bob. +Mallory would lose 10 happiness units by sitting next to Carol. +Mallory would gain 44 happiness units by sitting next to David. +Mallory would gain 22 happiness units by sitting next to Eric. +Mallory would gain 79 happiness units by sitting next to Frank. +Mallory would lose 16 happiness units by sitting next to George. diff --git a/2015/day13.py b/2015/day13.py new file mode 100644 index 0000000..ac01ee2 --- /dev/null +++ b/2015/day13.py @@ -0,0 +1,31 @@ +with open('day13-input', 'r') as file: + data = [l.strip('\n') for l in file] + +from itertools import permutations + +guests = set() +points = {} + +for line in data: + guest1, _, sign, point, _, _, _, _, _, _, guest2 = line.rstrip('.').split(' ') + guests.add(guest1) + guests.add(guest2) + mul = -1 if sign == 'lose' else +1 + points[(guest1, guest2)] = mul*int(point) + +route_points = [] +for route in permutations(guests): + route_points.append(sum([points[b, a]+points[b, c] for a, b, c in zip(route, route[1:]+route[:1], route[2:]+route[:2])])) +print(max(route_points)) # Part 1 + +guests.add('Me') +def get_points(guest1, guest2): + if guest1 == 'Me' or guest2 == 'Me': + return 0 + else: + return points[(guest1, guest2)] + +route_points_2 = [] +for route in permutations(guests): + route_points_2.append(sum([get_points(b, a)+get_points(b, c) for a, b, c in zip(route, route[1:]+route[:1], route[2:]+route[:2])])) +print(max(route_points_2)) # Part 2 diff --git a/2015/day14-input b/2015/day14-input new file mode 100644 index 0000000..1532578 --- /dev/null +++ b/2015/day14-input @@ -0,0 +1,9 @@ +Vixen can fly 8 km/s for 8 seconds, but then must rest for 53 seconds. +Blitzen can fly 13 km/s for 4 seconds, but then must rest for 49 seconds. +Rudolph can fly 20 km/s for 7 seconds, but then must rest for 132 seconds. +Cupid can fly 12 km/s for 4 seconds, but then must rest for 43 seconds. +Donner can fly 9 km/s for 5 seconds, but then must rest for 38 seconds. +Dasher can fly 10 km/s for 4 seconds, but then must rest for 37 seconds. +Comet can fly 3 km/s for 37 seconds, but then must rest for 76 seconds. +Prancer can fly 9 km/s for 12 seconds, but then must rest for 97 seconds. +Dancer can fly 37 km/s for 1 seconds, but then must rest for 36 seconds. diff --git a/2015/day14.py b/2015/day14.py new file mode 100644 index 0000000..d768b25 --- /dev/null +++ b/2015/day14.py @@ -0,0 +1,28 @@ +with open('day14-input', 'r') as file: + data = [l.strip('\n') for l in file] + +def deer(line): + name, _, _, speed, _, _, time, _, _, _, _, _, _, rest, _ = line.split() + return name, (int(speed), int(time), int(rest)) + +deers = {k:v for k, v in [deer(line) for line in data]} +def avg_speed(speed, time, rest): + return (speed*time)/(time+rest) +def distance(t, speed, time, rest): + period = time + rest + periods, remainder = divmod(t, period) + distance = periods * speed * time + distance += min(time, remainder) * speed + return distance + +print(max([distance(2503, *d) for d in deers.values()])) # Part 1 + +deerpoints = [0 for k in deers.keys()] +deerstats = [d for d in deers.values()] +for t in range(1, 2504): + deer_ds = [distance(t, *d) for d in deerstats] + lead_d = max(deer_ds) + for i, d in enumerate(deer_ds): + if d == lead_d: + deerpoints[i] += 1 +print(max(deerpoints)) # Part 2 diff --git a/2015/day15-input b/2015/day15-input new file mode 100644 index 0000000..d1af06e --- /dev/null +++ b/2015/day15-input @@ -0,0 +1,4 @@ +Sugar: capacity 3, durability 0, flavor 0, texture -3, calories 2 +Sprinkles: capacity -3, durability 3, flavor 0, texture 0, calories 9 +Candy: capacity -1, durability 0, flavor 4, texture 0, calories 1 +Chocolate: capacity 0, durability 0, flavor -2, texture 2, calories 8 diff --git a/2015/day17-input b/2015/day17-input new file mode 100644 index 0000000..588b253 --- /dev/null +++ b/2015/day17-input @@ -0,0 +1,20 @@ +50 +44 +11 +49 +42 +46 +18 +32 +26 +40 +21 +7 +18 +43 +10 +47 +36 +24 +22 +40 diff --git a/2015/day17.py b/2015/day17.py new file mode 100644 index 0000000..5297436 --- /dev/null +++ b/2015/day17.py @@ -0,0 +1,19 @@ +with open('day17-input', 'r') as file: + data = [int(l.strip('\n')) for l in file] +from itertools import combinations + +solutions = 0 +solution_sets = [] +for n in range(1, len(data)): + for c in combinations(data, n): + if sum(c) == 150: + solutions += 1 + solution_sets.append(c) +print(solutions) # Part 1 + +min_containers = min([len(c) for c in solution_sets]) +min_c_solutions = 0 +for c in solution_sets: + if len(c) == min_containers: + min_c_solutions += 1 +print(min_c_solutions) # Part 2 \ No newline at end of file diff --git a/2015/day20.py b/2015/day20.py new file mode 100644 index 0000000..69cf632 --- /dev/null +++ b/2015/day20.py @@ -0,0 +1,8 @@ +for i in range(1, 500001): + presents = 0 + for n in range(1, i+1): + if i%n == 0: + presents += 10*n + if presents >= 33100000: + print(i, presents) + break diff --git a/2018/day4-input b/2018/day4-input new file mode 100644 index 0000000..475b35a --- /dev/null +++ b/2018/day4-input @@ -0,0 +1,1131 @@ +[1518-05-28 00:59] wakes up +[1518-06-29 00:54] falls asleep +[1518-08-22 00:16] falls asleep +[1518-07-04 00:46] wakes up +[1518-09-02 00:00] Guard #2137 begins shift +[1518-05-01 00:45] falls asleep +[1518-08-15 00:47] wakes up +[1518-07-03 00:56] wakes up +[1518-11-17 00:02] Guard #563 begins shift +[1518-11-08 00:46] falls asleep +[1518-09-14 00:37] wakes up +[1518-03-06 00:49] wakes up +[1518-03-21 00:37] falls asleep +[1518-07-11 00:03] Guard #2083 begins shift +[1518-02-18 00:34] wakes up +[1518-06-02 00:38] wakes up +[1518-03-10 00:46] wakes up +[1518-10-12 00:23] falls asleep +[1518-03-02 00:55] falls asleep +[1518-10-06 00:17] wakes up +[1518-04-19 00:00] Guard #3511 begins shift +[1518-10-03 00:37] falls asleep +[1518-04-28 00:02] Guard #1499 begins shift +[1518-03-09 00:30] wakes up +[1518-08-17 00:00] Guard #2377 begins shift +[1518-07-04 00:58] wakes up +[1518-05-13 00:39] wakes up +[1518-07-06 00:41] falls asleep +[1518-08-06 23:57] Guard #983 begins shift +[1518-06-07 00:52] wakes up +[1518-10-04 00:00] Guard #1499 begins shift +[1518-08-17 00:21] falls asleep +[1518-02-18 00:17] falls asleep +[1518-03-23 00:57] wakes up +[1518-07-11 23:59] Guard #1709 begins shift +[1518-05-20 00:53] wakes up +[1518-11-22 00:50] falls asleep +[1518-10-28 00:16] wakes up +[1518-05-21 00:45] falls asleep +[1518-05-05 00:15] falls asleep +[1518-08-03 23:58] Guard #1499 begins shift +[1518-05-24 00:22] falls asleep +[1518-07-12 23:49] Guard #1499 begins shift +[1518-08-14 00:24] falls asleep +[1518-05-09 00:17] falls asleep +[1518-08-10 00:01] Guard #2591 begins shift +[1518-10-16 00:04] falls asleep +[1518-09-08 00:33] falls asleep +[1518-06-14 00:55] falls asleep +[1518-06-06 00:40] falls asleep +[1518-10-28 00:39] falls asleep +[1518-08-12 23:56] Guard #2267 begins shift +[1518-08-04 23:56] Guard #983 begins shift +[1518-09-04 00:34] falls asleep +[1518-06-14 00:46] falls asleep +[1518-09-29 00:22] wakes up +[1518-10-21 00:59] wakes up +[1518-07-27 00:59] wakes up +[1518-09-03 00:02] Guard #1499 begins shift +[1518-11-06 00:47] wakes up +[1518-07-12 00:52] falls asleep +[1518-03-06 00:06] falls asleep +[1518-10-17 00:46] wakes up +[1518-06-24 00:01] Guard #2663 begins shift +[1518-10-07 00:22] wakes up +[1518-11-06 00:02] Guard #3541 begins shift +[1518-05-21 00:49] wakes up +[1518-07-15 23:52] Guard #2591 begins shift +[1518-08-20 00:09] falls asleep +[1518-07-28 00:57] falls asleep +[1518-11-15 00:04] Guard #2083 begins shift +[1518-09-02 00:45] wakes up +[1518-07-08 00:30] falls asleep +[1518-07-24 00:03] Guard #2251 begins shift +[1518-05-22 00:01] falls asleep +[1518-05-28 00:47] falls asleep +[1518-08-08 00:40] falls asleep +[1518-03-06 00:14] falls asleep +[1518-07-03 00:02] Guard #2689 begins shift +[1518-02-17 00:48] wakes up +[1518-04-09 00:54] falls asleep +[1518-04-24 00:57] falls asleep +[1518-09-25 00:19] falls asleep +[1518-05-27 00:49] falls asleep +[1518-08-06 00:54] falls asleep +[1518-07-30 00:51] wakes up +[1518-08-26 00:17] falls asleep +[1518-10-05 00:44] wakes up +[1518-08-22 00:04] Guard #2251 begins shift +[1518-09-25 00:51] falls asleep +[1518-09-21 00:44] wakes up +[1518-04-02 00:59] wakes up +[1518-06-09 00:42] wakes up +[1518-03-23 00:34] wakes up +[1518-06-05 00:21] falls asleep +[1518-11-14 00:53] falls asleep +[1518-10-11 00:22] falls asleep +[1518-03-05 00:34] wakes up +[1518-05-24 00:02] Guard #2083 begins shift +[1518-11-03 23:58] Guard #2267 begins shift +[1518-05-09 00:21] wakes up +[1518-09-02 00:56] falls asleep +[1518-09-28 00:42] falls asleep +[1518-07-14 00:55] wakes up +[1518-07-02 00:15] falls asleep +[1518-10-13 00:34] falls asleep +[1518-02-22 00:03] falls asleep +[1518-04-04 23:57] Guard #2137 begins shift +[1518-06-05 00:46] falls asleep +[1518-02-14 00:53] wakes up +[1518-03-29 00:47] wakes up +[1518-10-19 00:42] wakes up +[1518-11-03 00:51] wakes up +[1518-02-15 23:47] Guard #79 begins shift +[1518-02-14 00:03] falls asleep +[1518-07-18 00:41] falls asleep +[1518-06-14 00:00] Guard #3541 begins shift +[1518-06-11 00:52] falls asleep +[1518-07-28 00:45] falls asleep +[1518-04-18 00:11] falls asleep +[1518-09-17 00:51] wakes up +[1518-04-03 00:56] wakes up +[1518-04-24 00:53] wakes up +[1518-04-30 00:41] falls asleep +[1518-05-11 00:00] Guard #631 begins shift +[1518-04-30 00:46] wakes up +[1518-04-30 00:20] wakes up +[1518-05-14 00:47] wakes up +[1518-11-11 23:56] Guard #2153 begins shift +[1518-10-29 00:57] falls asleep +[1518-03-11 00:02] Guard #2267 begins shift +[1518-10-07 00:29] falls asleep +[1518-03-26 00:48] wakes up +[1518-03-11 00:28] falls asleep +[1518-06-27 23:58] Guard #2713 begins shift +[1518-04-06 00:03] Guard #1499 begins shift +[1518-11-12 00:36] falls asleep +[1518-05-07 00:35] wakes up +[1518-06-18 00:43] wakes up +[1518-11-13 00:00] Guard #2663 begins shift +[1518-06-04 00:42] wakes up +[1518-11-16 00:13] falls asleep +[1518-06-22 00:54] wakes up +[1518-06-27 00:51] wakes up +[1518-08-28 00:38] wakes up +[1518-05-08 00:55] falls asleep +[1518-04-08 00:12] falls asleep +[1518-06-13 00:17] falls asleep +[1518-10-24 00:02] Guard #1259 begins shift +[1518-08-01 00:54] wakes up +[1518-11-15 00:07] falls asleep +[1518-05-15 00:29] falls asleep +[1518-07-13 00:51] wakes up +[1518-10-16 00:23] wakes up +[1518-03-21 00:58] wakes up +[1518-04-11 00:58] wakes up +[1518-02-17 00:39] falls asleep +[1518-08-18 00:21] falls asleep +[1518-04-01 00:11] falls asleep +[1518-09-06 23:58] Guard #1109 begins shift +[1518-06-03 00:38] falls asleep +[1518-07-30 00:46] falls asleep +[1518-04-21 00:42] falls asleep +[1518-04-29 00:16] falls asleep +[1518-09-22 00:43] falls asleep +[1518-07-04 00:12] falls asleep +[1518-09-06 00:40] wakes up +[1518-03-24 00:56] wakes up +[1518-08-20 00:23] falls asleep +[1518-05-22 00:13] falls asleep +[1518-03-15 00:53] wakes up +[1518-03-04 00:58] wakes up +[1518-08-15 00:46] falls asleep +[1518-04-09 00:10] falls asleep +[1518-07-14 00:09] falls asleep +[1518-04-27 00:19] falls asleep +[1518-10-17 00:04] Guard #2689 begins shift +[1518-05-27 00:57] wakes up +[1518-05-19 00:04] falls asleep +[1518-09-28 23:49] Guard #2591 begins shift +[1518-04-11 00:49] falls asleep +[1518-09-08 00:42] falls asleep +[1518-04-24 00:59] wakes up +[1518-07-01 00:55] falls asleep +[1518-02-19 00:55] wakes up +[1518-07-11 00:36] falls asleep +[1518-03-22 00:33] falls asleep +[1518-04-25 00:00] falls asleep +[1518-10-12 00:39] wakes up +[1518-07-26 00:23] falls asleep +[1518-05-26 00:53] wakes up +[1518-04-01 23:51] Guard #3511 begins shift +[1518-06-13 00:06] falls asleep +[1518-02-16 00:08] wakes up +[1518-09-07 23:51] Guard #2137 begins shift +[1518-09-15 00:04] Guard #1499 begins shift +[1518-11-10 23:56] Guard #2137 begins shift +[1518-05-08 00:58] wakes up +[1518-04-02 00:55] falls asleep +[1518-09-12 00:59] wakes up +[1518-04-13 00:28] wakes up +[1518-02-23 00:18] falls asleep +[1518-05-06 00:24] falls asleep +[1518-06-01 00:03] Guard #2083 begins shift +[1518-04-15 00:22] falls asleep +[1518-05-31 00:36] falls asleep +[1518-09-29 00:02] falls asleep +[1518-09-10 00:00] Guard #277 begins shift +[1518-05-31 00:56] wakes up +[1518-06-03 23:58] Guard #2083 begins shift +[1518-10-13 00:59] wakes up +[1518-03-15 00:42] falls asleep +[1518-09-22 00:01] Guard #2137 begins shift +[1518-10-08 00:25] wakes up +[1518-07-06 00:03] Guard #2797 begins shift +[1518-03-24 00:39] falls asleep +[1518-09-01 00:02] Guard #3079 begins shift +[1518-11-04 00:51] falls asleep +[1518-09-28 00:10] falls asleep +[1518-02-27 00:44] wakes up +[1518-11-09 00:27] wakes up +[1518-06-24 00:42] falls asleep +[1518-04-08 00:57] wakes up +[1518-10-11 00:03] Guard #1259 begins shift +[1518-07-26 23:58] Guard #2797 begins shift +[1518-11-23 00:53] wakes up +[1518-07-22 00:40] falls asleep +[1518-05-11 00:52] wakes up +[1518-03-31 00:23] wakes up +[1518-03-02 00:39] wakes up +[1518-03-31 23:56] Guard #1499 begins shift +[1518-09-05 00:31] falls asleep +[1518-11-07 00:04] Guard #2797 begins shift +[1518-06-15 00:29] wakes up +[1518-07-07 00:03] falls asleep +[1518-10-02 00:52] wakes up +[1518-03-20 00:26] falls asleep +[1518-02-27 00:53] wakes up +[1518-11-02 00:04] Guard #1109 begins shift +[1518-05-20 00:11] falls asleep +[1518-10-18 00:04] Guard #2251 begins shift +[1518-05-16 00:00] Guard #563 begins shift +[1518-10-02 00:35] falls asleep +[1518-04-13 00:44] wakes up +[1518-09-12 00:00] Guard #3541 begins shift +[1518-09-26 00:57] wakes up +[1518-06-01 00:19] falls asleep +[1518-10-08 00:53] wakes up +[1518-02-27 00:36] falls asleep +[1518-03-22 00:51] wakes up +[1518-08-30 00:00] falls asleep +[1518-08-25 00:24] wakes up +[1518-10-02 00:00] Guard #277 begins shift +[1518-10-29 00:59] wakes up +[1518-02-14 00:41] falls asleep +[1518-05-07 00:00] falls asleep +[1518-06-25 00:54] falls asleep +[1518-08-20 00:01] Guard #631 begins shift +[1518-02-24 23:52] Guard #79 begins shift +[1518-05-31 00:03] Guard #1259 begins shift +[1518-08-22 23:50] Guard #631 begins shift +[1518-08-18 00:40] wakes up +[1518-04-23 00:31] falls asleep +[1518-02-16 00:04] falls asleep +[1518-03-30 00:14] falls asleep +[1518-11-16 00:44] falls asleep +[1518-04-04 00:04] falls asleep +[1518-07-05 00:10] falls asleep +[1518-08-17 00:47] wakes up +[1518-05-20 00:38] wakes up +[1518-10-25 00:29] falls asleep +[1518-07-06 00:37] wakes up +[1518-04-24 00:04] Guard #3511 begins shift +[1518-02-26 23:56] Guard #277 begins shift +[1518-11-19 00:58] wakes up +[1518-05-08 00:29] falls asleep +[1518-08-19 00:44] falls asleep +[1518-02-28 00:27] falls asleep +[1518-05-23 00:36] falls asleep +[1518-11-08 00:54] wakes up +[1518-07-15 00:10] falls asleep +[1518-09-03 23:56] Guard #2153 begins shift +[1518-05-20 00:41] falls asleep +[1518-05-10 00:05] falls asleep +[1518-04-04 00:41] falls asleep +[1518-10-09 00:45] wakes up +[1518-06-14 00:43] wakes up +[1518-09-14 00:20] falls asleep +[1518-07-03 00:39] wakes up +[1518-05-07 00:30] falls asleep +[1518-03-25 00:17] falls asleep +[1518-03-31 00:16] falls asleep +[1518-06-21 00:14] falls asleep +[1518-10-08 00:47] falls asleep +[1518-10-04 00:43] falls asleep +[1518-10-06 00:02] Guard #2153 begins shift +[1518-04-01 00:47] wakes up +[1518-05-14 00:31] wakes up +[1518-03-28 00:41] wakes up +[1518-10-16 00:57] wakes up +[1518-03-12 00:04] Guard #2797 begins shift +[1518-08-24 00:39] wakes up +[1518-05-17 00:01] Guard #1499 begins shift +[1518-03-16 00:53] wakes up +[1518-07-07 00:56] wakes up +[1518-08-25 00:00] Guard #1709 begins shift +[1518-06-15 00:57] wakes up +[1518-03-07 00:21] falls asleep +[1518-07-02 00:16] wakes up +[1518-09-17 00:17] falls asleep +[1518-07-29 00:50] wakes up +[1518-09-22 23:48] Guard #2137 begins shift +[1518-03-06 23:46] Guard #2377 begins shift +[1518-10-26 00:20] falls asleep +[1518-07-12 00:57] wakes up +[1518-09-29 00:59] wakes up +[1518-09-23 00:00] falls asleep +[1518-10-20 00:54] wakes up +[1518-11-11 00:44] falls asleep +[1518-05-08 00:51] wakes up +[1518-03-30 00:42] falls asleep +[1518-06-22 00:00] Guard #3541 begins shift +[1518-02-19 00:43] wakes up +[1518-09-04 00:26] wakes up +[1518-02-20 00:02] Guard #79 begins shift +[1518-07-24 00:15] falls asleep +[1518-05-17 00:53] wakes up +[1518-10-19 00:39] falls asleep +[1518-10-14 00:50] falls asleep +[1518-03-30 00:31] wakes up +[1518-06-03 00:54] falls asleep +[1518-02-24 00:28] falls asleep +[1518-10-05 00:38] falls asleep +[1518-06-28 23:59] Guard #2591 begins shift +[1518-07-11 00:58] wakes up +[1518-07-22 00:52] falls asleep +[1518-11-01 00:53] wakes up +[1518-10-15 00:35] falls asleep +[1518-03-15 00:02] falls asleep +[1518-09-09 00:00] Guard #563 begins shift +[1518-09-04 00:06] falls asleep +[1518-03-01 00:03] falls asleep +[1518-02-22 23:59] Guard #2797 begins shift +[1518-10-09 00:39] wakes up +[1518-03-21 23:57] Guard #1259 begins shift +[1518-04-04 00:37] wakes up +[1518-05-21 23:50] Guard #2267 begins shift +[1518-09-28 00:36] wakes up +[1518-05-28 00:39] falls asleep +[1518-02-24 00:02] Guard #79 begins shift +[1518-10-11 00:56] wakes up +[1518-06-19 23:58] Guard #2689 begins shift +[1518-09-08 00:26] wakes up +[1518-11-14 00:30] wakes up +[1518-04-12 00:57] wakes up +[1518-06-06 00:46] wakes up +[1518-04-18 00:51] wakes up +[1518-05-21 00:33] wakes up +[1518-07-03 00:47] falls asleep +[1518-07-06 00:23] falls asleep +[1518-04-22 00:03] falls asleep +[1518-05-02 00:35] wakes up +[1518-10-04 00:54] falls asleep +[1518-09-08 00:38] wakes up +[1518-05-03 00:59] wakes up +[1518-11-09 00:25] falls asleep +[1518-10-26 00:49] wakes up +[1518-11-13 00:31] falls asleep +[1518-03-23 23:59] Guard #277 begins shift +[1518-07-27 00:43] falls asleep +[1518-10-28 00:03] falls asleep +[1518-07-25 00:10] falls asleep +[1518-08-17 23:58] Guard #2663 begins shift +[1518-09-24 00:50] wakes up +[1518-06-13 00:45] falls asleep +[1518-08-15 00:00] Guard #1709 begins shift +[1518-05-14 00:30] falls asleep +[1518-09-28 00:00] Guard #563 begins shift +[1518-07-22 00:42] wakes up +[1518-08-29 23:53] Guard #2689 begins shift +[1518-07-20 23:46] Guard #2377 begins shift +[1518-06-14 00:59] wakes up +[1518-09-21 00:35] falls asleep +[1518-03-09 00:48] wakes up +[1518-10-04 00:48] wakes up +[1518-04-17 00:45] wakes up +[1518-03-09 23:54] Guard #2797 begins shift +[1518-08-12 00:01] Guard #2713 begins shift +[1518-06-20 23:59] Guard #1259 begins shift +[1518-08-31 00:57] falls asleep +[1518-06-19 00:48] wakes up +[1518-06-14 23:48] Guard #2663 begins shift +[1518-10-22 00:46] wakes up +[1518-07-16 00:13] wakes up +[1518-09-06 00:10] falls asleep +[1518-03-19 00:57] wakes up +[1518-09-30 23:59] Guard #277 begins shift +[1518-04-07 00:51] falls asleep +[1518-04-03 00:04] Guard #277 begins shift +[1518-04-20 00:53] wakes up +[1518-06-24 00:59] wakes up +[1518-10-10 00:43] wakes up +[1518-06-30 00:59] wakes up +[1518-09-15 23:56] Guard #2797 begins shift +[1518-10-21 00:04] Guard #983 begins shift +[1518-06-25 23:52] Guard #2591 begins shift +[1518-04-21 00:53] wakes up +[1518-02-28 00:55] wakes up +[1518-03-11 00:09] falls asleep +[1518-04-12 00:34] falls asleep +[1518-09-20 00:28] wakes up +[1518-09-15 00:49] wakes up +[1518-05-30 00:58] wakes up +[1518-05-02 00:11] wakes up +[1518-05-20 00:00] Guard #631 begins shift +[1518-06-08 00:42] falls asleep +[1518-10-26 00:00] Guard #2083 begins shift +[1518-06-25 00:57] wakes up +[1518-06-29 00:58] wakes up +[1518-05-11 00:39] wakes up +[1518-09-20 00:23] falls asleep +[1518-08-10 00:56] wakes up +[1518-08-16 00:14] falls asleep +[1518-11-22 00:46] wakes up +[1518-11-21 23:46] Guard #1259 begins shift +[1518-05-16 00:29] falls asleep +[1518-08-05 00:55] falls asleep +[1518-04-29 00:53] wakes up +[1518-06-07 00:01] Guard #2377 begins shift +[1518-08-15 00:55] falls asleep +[1518-06-21 00:33] wakes up +[1518-07-29 00:01] falls asleep +[1518-09-26 00:39] falls asleep +[1518-03-14 00:57] wakes up +[1518-04-25 00:37] wakes up +[1518-04-06 00:32] falls asleep +[1518-11-14 00:37] falls asleep +[1518-08-31 00:58] wakes up +[1518-11-10 00:27] falls asleep +[1518-05-08 00:00] Guard #563 begins shift +[1518-02-28 00:38] wakes up +[1518-05-05 00:49] falls asleep +[1518-02-24 00:41] wakes up +[1518-11-21 00:08] falls asleep +[1518-08-29 00:46] falls asleep +[1518-09-24 00:54] falls asleep +[1518-03-11 00:29] wakes up +[1518-08-04 00:36] wakes up +[1518-07-22 00:02] Guard #2137 begins shift +[1518-07-28 00:59] wakes up +[1518-02-28 00:42] falls asleep +[1518-07-02 00:50] falls asleep +[1518-05-18 00:53] wakes up +[1518-07-15 00:23] wakes up +[1518-08-01 00:10] falls asleep +[1518-04-28 00:39] wakes up +[1518-09-04 00:13] falls asleep +[1518-03-04 00:50] falls asleep +[1518-11-07 00:47] wakes up +[1518-05-26 23:49] Guard #3541 begins shift +[1518-05-28 00:00] Guard #2251 begins shift +[1518-07-17 23:50] Guard #2377 begins shift +[1518-03-25 00:50] wakes up +[1518-09-17 00:00] falls asleep +[1518-05-21 00:04] Guard #563 begins shift +[1518-03-19 00:44] wakes up +[1518-11-20 00:39] wakes up +[1518-03-07 00:49] wakes up +[1518-03-14 23:53] Guard #2797 begins shift +[1518-10-02 23:59] Guard #983 begins shift +[1518-08-06 00:36] wakes up +[1518-07-31 00:26] falls asleep +[1518-07-28 00:53] wakes up +[1518-07-11 00:30] wakes up +[1518-05-02 00:19] falls asleep +[1518-06-21 00:56] wakes up +[1518-04-10 00:24] falls asleep +[1518-10-18 00:15] falls asleep +[1518-04-17 00:00] Guard #2137 begins shift +[1518-07-28 23:49] Guard #2797 begins shift +[1518-11-19 00:00] Guard #2153 begins shift +[1518-06-04 00:13] falls asleep +[1518-06-13 00:19] wakes up +[1518-09-15 00:32] falls asleep +[1518-07-11 00:49] falls asleep +[1518-03-30 00:52] wakes up +[1518-07-01 23:59] Guard #1259 begins shift +[1518-07-13 00:00] falls asleep +[1518-02-27 00:32] wakes up +[1518-10-30 00:15] wakes up +[1518-02-27 00:48] falls asleep +[1518-09-04 00:55] wakes up +[1518-09-19 00:04] falls asleep +[1518-07-15 00:53] wakes up +[1518-09-04 00:50] falls asleep +[1518-11-13 00:55] wakes up +[1518-05-13 00:59] wakes up +[1518-10-31 00:49] wakes up +[1518-10-24 00:54] falls asleep +[1518-04-02 00:51] wakes up +[1518-10-26 00:16] wakes up +[1518-10-07 23:53] Guard #2797 begins shift +[1518-05-30 00:30] wakes up +[1518-02-16 23:51] Guard #1709 begins shift +[1518-11-23 00:40] falls asleep +[1518-04-27 00:00] Guard #563 begins shift +[1518-04-28 00:30] falls asleep +[1518-02-21 00:38] wakes up +[1518-05-13 00:07] falls asleep +[1518-07-11 00:12] falls asleep +[1518-04-02 00:03] falls asleep +[1518-03-16 00:08] falls asleep +[1518-10-15 00:43] wakes up +[1518-02-15 00:47] wakes up +[1518-11-01 00:23] falls asleep +[1518-07-05 00:37] falls asleep +[1518-10-05 00:04] Guard #2137 begins shift +[1518-10-24 00:17] falls asleep +[1518-07-01 00:15] falls asleep +[1518-02-25 00:11] wakes up +[1518-06-09 00:34] falls asleep +[1518-06-24 00:36] wakes up +[1518-02-26 00:00] Guard #2689 begins shift +[1518-10-06 00:47] wakes up +[1518-10-14 00:02] Guard #2689 begins shift +[1518-04-29 00:00] Guard #2251 begins shift +[1518-03-10 00:57] wakes up +[1518-10-20 00:03] Guard #1259 begins shift +[1518-08-13 00:53] wakes up +[1518-03-18 00:34] falls asleep +[1518-08-21 00:58] wakes up +[1518-09-12 00:18] wakes up +[1518-05-12 00:02] Guard #2153 begins shift +[1518-07-15 00:04] Guard #2153 begins shift +[1518-06-03 00:02] Guard #277 begins shift +[1518-08-02 00:04] Guard #2797 begins shift +[1518-06-17 23:57] Guard #3541 begins shift +[1518-11-16 00:03] Guard #277 begins shift +[1518-07-18 00:26] wakes up +[1518-03-09 00:21] falls asleep +[1518-11-03 00:00] Guard #3511 begins shift +[1518-03-02 00:34] falls asleep +[1518-11-11 00:55] wakes up +[1518-05-23 00:04] Guard #2251 begins shift +[1518-06-12 00:42] falls asleep +[1518-09-11 00:55] wakes up +[1518-02-19 00:07] falls asleep +[1518-10-21 00:41] falls asleep +[1518-10-07 00:09] falls asleep +[1518-04-22 00:57] wakes up +[1518-02-16 00:13] falls asleep +[1518-05-16 00:48] falls asleep +[1518-08-21 00:53] falls asleep +[1518-04-06 00:50] falls asleep +[1518-10-09 00:42] falls asleep +[1518-07-01 00:26] wakes up +[1518-09-21 00:01] Guard #2797 begins shift +[1518-04-19 00:56] wakes up +[1518-06-18 00:31] falls asleep +[1518-04-11 00:52] wakes up +[1518-09-24 00:37] wakes up +[1518-07-05 00:29] wakes up +[1518-02-25 00:00] falls asleep +[1518-06-17 00:31] falls asleep +[1518-10-15 00:04] Guard #3511 begins shift +[1518-05-05 00:53] wakes up +[1518-03-08 00:31] wakes up +[1518-03-18 00:59] wakes up +[1518-07-15 00:27] falls asleep +[1518-11-17 00:59] wakes up +[1518-09-11 00:26] falls asleep +[1518-08-25 00:34] falls asleep +[1518-04-09 00:57] wakes up +[1518-04-23 00:02] Guard #2083 begins shift +[1518-03-18 23:58] Guard #2153 begins shift +[1518-11-15 00:48] wakes up +[1518-08-11 00:54] wakes up +[1518-03-28 00:59] wakes up +[1518-04-30 00:10] falls asleep +[1518-09-26 00:01] Guard #3541 begins shift +[1518-03-04 23:52] Guard #2377 begins shift +[1518-03-30 00:00] Guard #2689 begins shift +[1518-06-06 00:18] falls asleep +[1518-05-07 00:57] wakes up +[1518-07-19 00:48] wakes up +[1518-05-09 23:51] Guard #2377 begins shift +[1518-05-01 00:57] wakes up +[1518-03-02 00:01] Guard #1499 begins shift +[1518-03-23 00:22] falls asleep +[1518-06-24 00:27] falls asleep +[1518-09-27 00:49] wakes up +[1518-02-17 00:32] wakes up +[1518-07-21 00:47] wakes up +[1518-10-22 00:37] falls asleep +[1518-04-05 00:14] wakes up +[1518-10-15 23:49] Guard #79 begins shift +[1518-08-04 00:54] wakes up +[1518-03-07 00:31] falls asleep +[1518-04-30 23:56] Guard #2689 begins shift +[1518-06-15 00:05] falls asleep +[1518-10-16 00:53] falls asleep +[1518-07-18 00:03] falls asleep +[1518-03-07 00:02] falls asleep +[1518-07-16 23:58] Guard #1109 begins shift +[1518-05-29 00:52] falls asleep +[1518-03-27 23:58] Guard #3511 begins shift +[1518-03-27 00:16] falls asleep +[1518-07-21 00:03] falls asleep +[1518-02-14 00:22] wakes up +[1518-08-26 00:35] wakes up +[1518-09-19 00:50] wakes up +[1518-09-10 00:24] falls asleep +[1518-02-20 23:59] Guard #3511 begins shift +[1518-04-19 00:36] falls asleep +[1518-09-18 00:38] falls asleep +[1518-04-15 00:59] wakes up +[1518-03-07 00:06] wakes up +[1518-07-14 00:43] falls asleep +[1518-05-29 00:55] wakes up +[1518-07-25 23:58] Guard #1709 begins shift +[1518-05-12 23:56] Guard #277 begins shift +[1518-11-04 00:55] wakes up +[1518-07-27 00:52] wakes up +[1518-06-08 00:00] Guard #2689 begins shift +[1518-04-14 00:56] wakes up +[1518-10-07 00:03] Guard #2377 begins shift +[1518-10-25 00:51] wakes up +[1518-05-17 23:57] Guard #79 begins shift +[1518-04-07 00:35] wakes up +[1518-10-23 00:01] Guard #563 begins shift +[1518-06-13 00:59] wakes up +[1518-06-13 00:02] Guard #2591 begins shift +[1518-08-19 00:58] wakes up +[1518-03-12 00:30] falls asleep +[1518-06-12 00:12] wakes up +[1518-10-01 00:18] falls asleep +[1518-08-30 00:34] falls asleep +[1518-02-15 00:02] Guard #2267 begins shift +[1518-04-20 23:59] Guard #2267 begins shift +[1518-02-17 00:01] falls asleep +[1518-06-17 00:54] wakes up +[1518-11-16 00:41] wakes up +[1518-04-03 23:50] Guard #1499 begins shift +[1518-04-20 00:01] falls asleep +[1518-07-18 00:47] wakes up +[1518-08-16 00:03] Guard #2251 begins shift +[1518-04-28 00:38] falls asleep +[1518-10-21 00:50] wakes up +[1518-08-26 23:58] Guard #2251 begins shift +[1518-09-04 00:36] wakes up +[1518-04-03 00:36] falls asleep +[1518-03-11 00:23] wakes up +[1518-09-16 00:44] wakes up +[1518-02-26 00:52] wakes up +[1518-08-06 00:08] falls asleep +[1518-10-10 00:38] falls asleep +[1518-05-30 00:08] falls asleep +[1518-07-29 23:52] Guard #2377 begins shift +[1518-10-23 00:51] falls asleep +[1518-04-27 00:55] wakes up +[1518-05-19 00:54] wakes up +[1518-10-14 00:51] wakes up +[1518-06-29 00:48] wakes up +[1518-03-03 00:27] falls asleep +[1518-04-30 00:03] Guard #563 begins shift +[1518-09-02 00:58] wakes up +[1518-10-29 00:00] Guard #2663 begins shift +[1518-08-16 00:58] wakes up +[1518-05-18 00:11] falls asleep +[1518-05-01 00:38] wakes up +[1518-07-31 00:01] Guard #2663 begins shift +[1518-11-12 00:59] wakes up +[1518-11-18 00:03] Guard #2713 begins shift +[1518-03-25 23:58] Guard #2137 begins shift +[1518-06-10 00:40] falls asleep +[1518-06-14 00:38] falls asleep +[1518-05-13 00:55] falls asleep +[1518-08-20 00:15] wakes up +[1518-11-08 23:58] Guard #1709 begins shift +[1518-03-14 00:17] falls asleep +[1518-04-09 23:56] Guard #2083 begins shift +[1518-03-12 00:54] wakes up +[1518-11-08 00:42] wakes up +[1518-07-30 00:35] wakes up +[1518-05-14 00:02] Guard #2797 begins shift +[1518-05-05 00:03] Guard #2591 begins shift +[1518-05-29 00:37] wakes up +[1518-02-21 00:43] falls asleep +[1518-06-12 00:36] wakes up +[1518-07-26 00:46] wakes up +[1518-06-29 00:20] falls asleep +[1518-09-17 00:14] wakes up +[1518-06-05 23:59] Guard #79 begins shift +[1518-10-20 00:17] falls asleep +[1518-06-14 00:48] wakes up +[1518-09-04 00:07] wakes up +[1518-08-26 00:00] Guard #2689 begins shift +[1518-05-10 00:34] wakes up +[1518-04-05 00:56] wakes up +[1518-06-26 00:00] falls asleep +[1518-06-29 23:53] Guard #2267 begins shift +[1518-11-05 00:51] wakes up +[1518-04-19 00:28] wakes up +[1518-08-31 00:14] falls asleep +[1518-05-04 00:08] falls asleep +[1518-03-02 00:57] wakes up +[1518-10-30 00:07] falls asleep +[1518-08-03 00:01] Guard #1499 begins shift +[1518-11-20 00:00] Guard #2689 begins shift +[1518-07-06 00:53] wakes up +[1518-10-07 00:43] wakes up +[1518-07-10 00:13] falls asleep +[1518-07-13 00:34] falls asleep +[1518-03-05 23:57] Guard #2251 begins shift +[1518-06-03 00:46] wakes up +[1518-06-05 00:58] wakes up +[1518-08-13 00:49] falls asleep +[1518-09-27 00:02] Guard #277 begins shift +[1518-05-30 00:03] Guard #2377 begins shift +[1518-09-16 23:51] Guard #563 begins shift +[1518-05-15 00:00] Guard #1499 begins shift +[1518-08-27 00:55] wakes up +[1518-04-05 00:40] falls asleep +[1518-02-21 23:50] Guard #2663 begins shift +[1518-10-18 00:58] wakes up +[1518-09-05 23:56] Guard #2377 begins shift +[1518-07-20 00:02] Guard #2251 begins shift +[1518-08-02 00:16] falls asleep +[1518-10-27 00:35] wakes up +[1518-06-11 00:57] wakes up +[1518-10-16 00:36] falls asleep +[1518-03-18 00:30] wakes up +[1518-10-06 00:10] falls asleep +[1518-08-04 00:31] falls asleep +[1518-03-15 00:31] wakes up +[1518-09-09 00:42] wakes up +[1518-11-23 00:31] wakes up +[1518-08-02 00:29] wakes up +[1518-09-10 00:52] wakes up +[1518-07-04 00:50] falls asleep +[1518-07-31 00:53] wakes up +[1518-03-13 23:56] Guard #631 begins shift +[1518-07-20 00:12] falls asleep +[1518-03-27 00:45] wakes up +[1518-09-25 00:55] wakes up +[1518-07-05 00:47] wakes up +[1518-08-01 00:04] Guard #2153 begins shift +[1518-09-03 00:26] falls asleep +[1518-03-31 00:00] Guard #2267 begins shift +[1518-10-04 00:33] falls asleep +[1518-03-08 00:59] wakes up +[1518-09-12 00:10] falls asleep +[1518-10-25 00:09] falls asleep +[1518-05-01 00:25] falls asleep +[1518-10-09 00:53] wakes up +[1518-11-01 00:00] Guard #2153 begins shift +[1518-05-03 00:01] Guard #1499 begins shift +[1518-11-14 00:17] wakes up +[1518-09-24 00:56] wakes up +[1518-09-25 00:01] Guard #2663 begins shift +[1518-03-17 00:04] falls asleep +[1518-03-24 00:35] wakes up +[1518-04-26 00:04] Guard #1259 begins shift +[1518-04-19 00:18] falls asleep +[1518-08-31 00:50] wakes up +[1518-02-26 00:12] falls asleep +[1518-03-13 00:01] Guard #1109 begins shift +[1518-09-30 00:04] falls asleep +[1518-10-28 00:51] wakes up +[1518-05-07 00:12] falls asleep +[1518-08-29 00:53] wakes up +[1518-09-30 00:46] wakes up +[1518-05-22 00:52] wakes up +[1518-08-23 00:03] falls asleep +[1518-09-08 00:48] wakes up +[1518-05-18 23:48] Guard #2267 begins shift +[1518-10-21 00:56] falls asleep +[1518-10-04 00:59] wakes up +[1518-03-16 00:00] Guard #631 begins shift +[1518-07-28 00:02] Guard #2083 begins shift +[1518-07-22 23:58] Guard #3079 begins shift +[1518-05-26 00:43] falls asleep +[1518-06-09 00:47] wakes up +[1518-10-26 23:53] Guard #1499 begins shift +[1518-03-05 00:02] falls asleep +[1518-05-11 00:24] falls asleep +[1518-07-10 00:22] wakes up +[1518-11-22 00:00] falls asleep +[1518-07-03 00:14] falls asleep +[1518-08-30 00:59] wakes up +[1518-04-19 00:41] wakes up +[1518-08-05 00:56] wakes up +[1518-08-11 00:03] Guard #3511 begins shift +[1518-10-04 00:38] wakes up +[1518-11-22 00:24] falls asleep +[1518-03-09 00:03] wakes up +[1518-06-05 00:01] Guard #2797 begins shift +[1518-07-14 00:38] wakes up +[1518-03-05 00:29] falls asleep +[1518-03-25 00:00] Guard #983 begins shift +[1518-06-30 00:00] falls asleep +[1518-02-19 00:51] falls asleep +[1518-11-10 00:59] wakes up +[1518-06-10 00:49] wakes up +[1518-07-11 00:54] wakes up +[1518-04-17 00:24] falls asleep +[1518-10-10 00:04] Guard #2083 begins shift +[1518-10-29 00:19] falls asleep +[1518-07-19 00:02] falls asleep +[1518-03-28 00:54] falls asleep +[1518-06-20 00:10] falls asleep +[1518-03-17 00:46] wakes up +[1518-06-17 00:03] falls asleep +[1518-11-20 00:28] falls asleep +[1518-05-12 00:27] falls asleep +[1518-08-11 00:13] falls asleep +[1518-09-29 00:54] falls asleep +[1518-07-05 00:01] Guard #2251 begins shift +[1518-05-24 00:56] wakes up +[1518-03-27 00:02] Guard #277 begins shift +[1518-03-23 00:39] falls asleep +[1518-08-06 00:55] wakes up +[1518-11-20 23:57] Guard #3511 begins shift +[1518-11-21 00:19] wakes up +[1518-03-20 00:03] Guard #277 begins shift +[1518-11-14 00:24] falls asleep +[1518-05-01 23:56] Guard #2591 begins shift +[1518-06-03 00:55] wakes up +[1518-10-03 00:52] wakes up +[1518-05-22 00:10] wakes up +[1518-11-09 23:59] Guard #2083 begins shift +[1518-04-13 00:32] falls asleep +[1518-06-18 23:57] Guard #2251 begins shift +[1518-08-03 00:11] falls asleep +[1518-03-18 00:22] falls asleep +[1518-08-20 00:59] wakes up +[1518-04-26 00:11] falls asleep +[1518-08-31 00:00] Guard #3511 begins shift +[1518-08-07 00:09] falls asleep +[1518-11-05 00:00] Guard #2663 begins shift +[1518-09-11 00:04] Guard #2377 begins shift +[1518-07-14 00:00] Guard #79 begins shift +[1518-10-24 23:56] Guard #79 begins shift +[1518-04-06 23:58] Guard #1259 begins shift +[1518-02-27 00:10] falls asleep +[1518-10-27 23:50] Guard #79 begins shift +[1518-06-27 00:00] falls asleep +[1518-09-24 00:16] falls asleep +[1518-02-17 23:57] Guard #277 begins shift +[1518-07-10 00:36] wakes up +[1518-07-22 00:57] wakes up +[1518-03-19 00:55] falls asleep +[1518-08-28 23:59] Guard #631 begins shift +[1518-06-26 00:25] wakes up +[1518-08-09 00:01] falls asleep +[1518-03-10 00:49] falls asleep +[1518-07-08 00:00] Guard #1259 begins shift +[1518-04-24 00:32] falls asleep +[1518-04-13 00:04] Guard #79 begins shift +[1518-07-04 00:03] Guard #2083 begins shift +[1518-06-16 23:48] Guard #2267 begins shift +[1518-09-12 23:59] Guard #2713 begins shift +[1518-10-21 23:58] Guard #2083 begins shift +[1518-08-15 00:58] wakes up +[1518-09-24 00:48] falls asleep +[1518-07-11 00:46] wakes up +[1518-08-28 00:12] falls asleep +[1518-06-30 00:44] falls asleep +[1518-09-04 23:58] Guard #2377 begins shift +[1518-04-09 00:01] Guard #79 begins shift +[1518-10-02 00:47] falls asleep +[1518-11-19 00:51] falls asleep +[1518-03-21 00:00] Guard #277 begins shift +[1518-04-04 00:46] wakes up +[1518-11-07 23:58] Guard #631 begins shift +[1518-08-03 00:58] wakes up +[1518-11-08 00:30] falls asleep +[1518-03-06 00:11] wakes up +[1518-06-09 23:56] Guard #277 begins shift +[1518-03-26 00:26] falls asleep +[1518-04-08 00:00] Guard #79 begins shift +[1518-03-09 00:02] falls asleep +[1518-09-02 00:25] falls asleep +[1518-03-02 23:56] Guard #1499 begins shift +[1518-08-13 00:26] falls asleep +[1518-09-20 00:02] Guard #563 begins shift +[1518-11-03 00:08] falls asleep +[1518-05-06 00:44] wakes up +[1518-08-08 00:00] Guard #631 begins shift +[1518-06-07 00:27] wakes up +[1518-06-07 00:34] falls asleep +[1518-03-17 00:57] wakes up +[1518-03-10 00:04] falls asleep +[1518-06-12 00:44] wakes up +[1518-07-02 00:57] wakes up +[1518-03-29 00:03] Guard #2251 begins shift +[1518-08-28 00:03] Guard #1499 begins shift +[1518-08-26 00:55] wakes up +[1518-04-15 00:40] wakes up +[1518-04-17 23:56] Guard #2251 begins shift +[1518-07-25 00:52] wakes up +[1518-04-28 00:35] wakes up +[1518-10-16 00:42] wakes up +[1518-04-22 00:43] wakes up +[1518-03-03 00:56] wakes up +[1518-10-18 23:58] Guard #2663 begins shift +[1518-09-02 00:06] falls asleep +[1518-08-22 00:58] wakes up +[1518-03-04 00:00] Guard #2153 begins shift +[1518-03-23 00:00] Guard #2251 begins shift +[1518-02-28 00:04] Guard #2251 begins shift +[1518-02-16 00:50] wakes up +[1518-04-11 00:56] falls asleep +[1518-10-24 00:41] wakes up +[1518-08-08 00:49] wakes up +[1518-03-05 00:24] wakes up +[1518-06-24 23:57] Guard #3541 begins shift +[1518-05-21 00:24] falls asleep +[1518-08-10 00:47] falls asleep +[1518-03-08 00:22] falls asleep +[1518-09-09 00:10] falls asleep +[1518-04-10 23:59] Guard #79 begins shift +[1518-06-22 23:57] Guard #3079 begins shift +[1518-08-23 00:56] wakes up +[1518-09-18 00:40] wakes up +[1518-10-25 00:17] wakes up +[1518-05-30 00:56] falls asleep +[1518-10-30 00:04] Guard #2591 begins shift +[1518-09-22 00:57] wakes up +[1518-08-07 00:20] wakes up +[1518-10-26 00:11] falls asleep +[1518-03-08 00:37] falls asleep +[1518-04-07 00:55] wakes up +[1518-05-05 00:31] wakes up +[1518-03-17 00:53] falls asleep +[1518-05-14 00:42] falls asleep +[1518-06-30 00:21] wakes up +[1518-08-05 00:43] falls asleep +[1518-06-09 00:45] falls asleep +[1518-05-06 00:03] Guard #2153 begins shift +[1518-04-30 00:24] falls asleep +[1518-05-28 00:43] wakes up +[1518-03-07 00:26] wakes up +[1518-06-12 00:03] Guard #2377 begins shift +[1518-06-12 00:19] falls asleep +[1518-03-01 00:55] wakes up +[1518-07-10 00:02] Guard #1709 begins shift +[1518-07-31 00:42] wakes up +[1518-08-05 23:57] Guard #2267 begins shift +[1518-07-31 00:51] falls asleep +[1518-04-11 23:58] Guard #631 begins shift +[1518-08-04 00:48] falls asleep +[1518-11-08 00:58] wakes up +[1518-05-29 00:11] falls asleep +[1518-05-17 00:08] falls asleep +[1518-10-09 00:04] Guard #983 begins shift +[1518-03-09 00:44] falls asleep +[1518-03-19 00:18] falls asleep +[1518-07-10 00:30] falls asleep +[1518-07-01 00:56] wakes up +[1518-09-08 00:05] falls asleep +[1518-05-23 00:58] wakes up +[1518-11-11 00:34] wakes up +[1518-07-25 00:04] Guard #277 begins shift +[1518-09-16 00:27] falls asleep +[1518-05-29 00:01] Guard #2267 begins shift +[1518-08-27 00:47] falls asleep +[1518-10-12 00:03] Guard #2251 begins shift +[1518-04-22 00:29] falls asleep +[1518-07-01 00:00] Guard #2083 begins shift +[1518-09-03 00:45] wakes up +[1518-02-15 00:11] falls asleep +[1518-11-12 00:14] falls asleep +[1518-11-07 00:31] falls asleep +[1518-10-30 23:57] Guard #2689 begins shift +[1518-05-16 00:56] wakes up +[1518-10-17 00:15] falls asleep +[1518-07-16 00:03] falls asleep +[1518-04-30 00:26] wakes up +[1518-02-21 00:37] falls asleep +[1518-03-20 00:39] wakes up +[1518-04-22 00:47] falls asleep +[1518-04-05 00:12] falls asleep +[1518-05-07 00:07] wakes up +[1518-06-16 00:41] falls asleep +[1518-02-21 00:45] wakes up +[1518-10-02 00:44] wakes up +[1518-07-21 00:09] wakes up +[1518-05-25 23:59] Guard #2153 begins shift +[1518-09-13 23:56] Guard #1499 begins shift +[1518-10-06 00:39] falls asleep +[1518-11-12 00:18] wakes up +[1518-05-04 00:00] Guard #2377 begins shift +[1518-11-05 00:23] falls asleep +[1518-06-15 00:41] falls asleep +[1518-06-07 00:23] falls asleep +[1518-09-18 00:01] Guard #277 begins shift +[1518-10-24 00:56] wakes up +[1518-06-16 00:03] Guard #2251 begins shift +[1518-08-09 00:54] wakes up +[1518-11-11 00:28] falls asleep +[1518-08-19 00:00] Guard #983 begins shift +[1518-09-21 00:53] wakes up +[1518-09-23 00:45] wakes up +[1518-11-22 00:15] wakes up +[1518-09-12 00:46] falls asleep +[1518-09-27 00:29] falls asleep +[1518-08-15 00:38] falls asleep +[1518-04-15 00:54] falls asleep +[1518-10-31 00:22] falls asleep +[1518-04-16 00:01] Guard #1109 begins shift +[1518-05-07 00:14] wakes up +[1518-06-05 00:42] wakes up +[1518-06-16 00:45] wakes up +[1518-07-08 00:41] wakes up +[1518-04-21 23:46] Guard #2663 begins shift +[1518-09-02 00:22] wakes up +[1518-03-08 00:00] Guard #631 begins shift +[1518-08-25 00:46] falls asleep +[1518-06-12 00:06] falls asleep +[1518-02-22 00:37] wakes up +[1518-09-25 00:45] wakes up +[1518-04-15 00:01] Guard #2797 begins shift +[1518-02-19 00:04] Guard #2267 begins shift +[1518-07-20 00:46] wakes up +[1518-11-23 00:00] Guard #277 begins shift +[1518-09-24 00:04] Guard #2251 begins shift +[1518-08-08 23:47] Guard #1709 begins shift +[1518-07-13 00:28] wakes up +[1518-04-06 00:37] wakes up +[1518-03-29 00:36] falls asleep +[1518-03-16 23:54] Guard #631 begins shift +[1518-09-28 00:57] wakes up +[1518-11-16 00:49] wakes up +[1518-06-08 00:50] wakes up +[1518-06-17 00:18] wakes up +[1518-06-06 00:35] wakes up +[1518-11-08 00:57] falls asleep +[1518-08-23 23:54] Guard #2663 begins shift +[1518-10-27 00:00] falls asleep +[1518-05-12 00:57] wakes up +[1518-11-17 00:13] falls asleep +[1518-07-27 00:57] falls asleep +[1518-05-03 00:10] falls asleep +[1518-03-08 23:51] Guard #631 begins shift +[1518-11-06 00:11] falls asleep +[1518-02-20 00:46] falls asleep +[1518-06-20 00:37] wakes up +[1518-11-14 00:11] falls asleep +[1518-05-08 23:59] Guard #2663 begins shift +[1518-05-18 00:29] wakes up +[1518-09-05 00:59] wakes up +[1518-10-13 00:03] Guard #2251 begins shift +[1518-11-14 00:58] wakes up +[1518-04-14 00:29] falls asleep +[1518-02-23 00:58] wakes up +[1518-03-18 00:03] Guard #2137 begins shift +[1518-10-23 00:53] wakes up +[1518-05-15 00:46] wakes up +[1518-06-02 00:03] Guard #3511 begins shift +[1518-07-09 00:46] wakes up +[1518-07-24 00:39] wakes up +[1518-07-06 23:52] Guard #2137 begins shift +[1518-02-28 23:46] Guard #3511 begins shift +[1518-08-25 00:10] falls asleep +[1518-06-11 00:01] Guard #2137 begins shift +[1518-06-02 00:13] falls asleep +[1518-08-05 00:50] wakes up +[1518-11-22 00:55] wakes up +[1518-10-09 00:13] falls asleep +[1518-07-08 23:46] Guard #2153 begins shift +[1518-04-10 00:50] wakes up +[1518-04-13 23:58] Guard #631 begins shift +[1518-05-07 00:54] falls asleep +[1518-06-19 00:31] falls asleep +[1518-08-24 00:04] falls asleep +[1518-04-23 00:37] wakes up +[1518-09-18 23:46] Guard #2377 begins shift +[1518-07-21 00:27] falls asleep +[1518-03-28 00:31] falls asleep +[1518-05-18 00:32] falls asleep +[1518-05-04 00:48] wakes up +[1518-07-11 00:57] falls asleep +[1518-04-06 00:55] wakes up +[1518-08-13 00:43] wakes up +[1518-03-24 00:14] falls asleep +[1518-05-25 00:00] Guard #2713 begins shift +[1518-04-19 23:54] Guard #2153 begins shift +[1518-04-13 00:25] falls asleep +[1518-04-19 00:51] falls asleep +[1518-11-23 00:14] falls asleep +[1518-10-08 00:00] falls asleep +[1518-09-21 00:47] falls asleep +[1518-05-02 00:09] falls asleep +[1518-04-07 00:18] falls asleep +[1518-07-30 00:03] falls asleep +[1518-08-21 00:03] Guard #2137 begins shift +[1518-11-13 23:59] Guard #2267 begins shift +[1518-08-14 00:51] wakes up +[1518-08-26 00:47] falls asleep +[1518-04-22 00:05] wakes up +[1518-04-24 23:51] Guard #1709 begins shift +[1518-06-13 00:07] wakes up +[1518-03-22 00:41] wakes up +[1518-10-09 00:49] falls asleep +[1518-05-27 00:05] falls asleep +[1518-09-29 23:48] Guard #79 begins shift +[1518-06-01 00:50] wakes up +[1518-05-16 00:35] wakes up +[1518-07-09 00:02] falls asleep +[1518-06-22 00:46] falls asleep +[1518-08-15 00:39] wakes up +[1518-06-26 23:50] Guard #2377 begins shift +[1518-10-01 00:50] wakes up +[1518-07-18 23:49] Guard #277 begins shift +[1518-05-06 23:50] Guard #631 begins shift +[1518-04-09 00:42] wakes up +[1518-08-25 00:39] wakes up +[1518-02-13 23:47] Guard #2797 begins shift +[1518-05-11 00:47] falls asleep +[1518-06-09 00:04] Guard #2137 begins shift +[1518-06-21 00:36] falls asleep +[1518-02-20 00:52] wakes up +[1518-10-29 00:43] wakes up +[1518-08-25 00:51] wakes up +[1518-11-14 00:50] wakes up +[1518-03-22 00:47] falls asleep +[1518-04-26 00:54] wakes up +[1518-05-27 00:41] wakes up +[1518-08-30 00:21] wakes up +[1518-08-14 00:02] Guard #1499 begins shift diff --git a/2018/day4.py b/2018/day4.py new file mode 100644 index 0000000..0a4ada1 --- /dev/null +++ b/2018/day4.py @@ -0,0 +1,53 @@ +with open('day4-input', 'r') as file: + data = sorted([l.strip('\n') for l in file]) +import numpy as np + +GUARDs = {} +GUARD = None +GUARD_asleep = False +GUARD_sleeptime = 0 + +def parse(line): + global GUARD, GUARD_asleep, GUARD_sleeptime + date, time, *event = line.split() + date = date.lstrip('[') + time = time.rstrip(']') + minute = int(time.partition(':')[2]) + if event[0] == 'Guard': + if GUARD_asleep and GUARD: + GUARDs[GUARD][GUARD_sleeptime:minute] += 1 + GUARD = int(event[1].lstrip('#')) + if GUARD not in GUARDs: + GUARDs[GUARD] = np.zeros((60)) + GUARD_asleep = False + elif event[0] == 'wakes': + GUARD_asleep = False + if GUARD: + GUARDs[GUARD][GUARD_sleeptime:minute] += 1 + else: # falls asleep + GUARD_asleep = True + GUARD_sleeptime = minute + + +for line in data: + parse(line) + +max_mins = 0 +max_g = None +for k, v in GUARDs.items(): + val = v.sum() + if val > max_mins: + max_mins = val + max_g = k +biggest_minute = GUARDs[max_g].argmax() +print(max_g*biggest_minute) # Part 1 + + +max_mins_2 = 0 +max_g_2 = None +for k, v in GUARDs.items(): + val = v.max() + if val > max_mins_2: + max_mins_2 = val + max_g_2 = k +print(max_g_2*GUARDs[max_g_2].argmax()) # Part 1 \ No newline at end of file