summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--20/py/d07.py5
-rw-r--r--20/py/d08.py5
2 files changed, 9 insertions, 1 deletions
diff --git a/20/py/d07.py b/20/py/d07.py
index e484f2b..48fa3d2 100644
--- a/20/py/d07.py
+++ b/20/py/d07.py
@@ -2,6 +2,7 @@
import sys
import regex as re
import functools
+import time
class Node:
@@ -49,5 +50,7 @@ if __name__ == "__main__":
input = open("../input/07", "r").readlines()
# graph(parse(input))
- print(pt1(input))
+ start = time.time()
print(pt2(input))
+ print(pt1(input))
+ print(time.time() - start)
diff --git a/20/py/d08.py b/20/py/d08.py
index 081b7b2..550fb3b 100644
--- a/20/py/d08.py
+++ b/20/py/d08.py
@@ -1,5 +1,6 @@
#!/usr/bin/env python3
import sys
+import time
def parse(prog):
@@ -49,5 +50,9 @@ if __name__ == "__main__":
input = open(sys.argv[1], "r").readlines()
else:
input = open("../input/08", "r").readlines()
+ start = time.time()
+ input = parse(input)
print(pt1(input))
+ print("pt1 {:.3}".format(time.time() - start))
print(pt2(input))
+ print("pt2 {:.3}".format(time.time() - start))