summaryrefslogtreecommitdiffstats
path: root/solutions/py/d03.py
diff options
context:
space:
mode:
Diffstat (limited to 'solutions/py/d03.py')
-rw-r--r--solutions/py/d03.py9
1 files changed, 9 insertions, 0 deletions
diff --git a/solutions/py/d03.py b/solutions/py/d03.py
index aec6d4a..2454cb3 100644
--- a/solutions/py/d03.py
+++ b/solutions/py/d03.py
@@ -73,3 +73,12 @@ def pt2(input):
for point in points[1:]:
length = min(length, wire1[point] + wire2[point])
return length
+
+if __name__ == "__main__":
+ import cProfile
+
+ input = open("../input/03", "r").readlines()
+ cProfile.run("pt1(input)")
+ cProfile.run("pt2(input)")
+ print(pt1(input))
+ print(pt2(input))