updated open script

This commit is contained in:
2020-12-18 09:21:16 +01:00
parent 0af6bb9594
commit e1df2a6d5a
2 changed files with 40 additions and 3 deletions

36
module.py Normal file
View File

@@ -0,0 +1,36 @@
from aoc.input import get_input
import copy
import itertools
import time
import collections
import re
from aoc.partselector import part_one, part_two
import functools
def pw(line):
return line.strip()
def p1():
inp = get_input(pw)
for sample in inp:
print(sample)
return inp
def p2(segments):
print(len(segments))
return 0
result1 = None
if part_one():
start = time.time()
result1 = p1()
print(round(1000*(time.time() - start), 2), 'ms')
if part_two():
start = time.time()
p2(result1)
print(round(1000*(time.time() - start), 2), 'ms')