rj1
about | log | files | refs
commit e0ee3530d9e355c2c79f2913325878357b8c0113
parent 781234c8db8d3d35681c0520735c3ccee7bc3666
author: rj1 <[email protected]>
date:   Wed, 30 Nov 2022 13:49:00 -0600

added a template for solutions so we can start quicker

Diffstat:
Mget-input | 3+++
Atemplate.py | 7+++++++
2 files changed, 10 insertions(+), 0 deletions(-)

diff --git a/get-input b/get-input @@ -3,6 +3,7 @@ import requests import os from zoneinfo import ZoneInfo from datetime import datetime +import shutil base_dir = os.path.realpath(os.path.dirname(__file__)) @@ -25,4 +26,6 @@ input_file = f"{dir}/input.txt" with open(input_file, "wb") as f: f.write(response.content) +shutil.copyfile(base_dir + "/template.py", dir + "/solution.py") + print(f"todays input saved to {input_file}") diff --git a/template.py b/template.py @@ -0,0 +1,7 @@ +import os + +base_dir = os.path.realpath(os.path.dirname(__file__)) +with open(base_dir + "/input.txt", "r") as file: + input = file.read().rstrip() + +# lines = input.split("\n")