2015 day 2

This commit is contained in:
2024-12-06 20:01:37 +01:00
parent 88913b55f0
commit 6372d5d477
6 changed files with 1064 additions and 2 deletions

View File

@@ -1,4 +1,11 @@
input = open("input.txt").read()
import os
script_dir = os.path.dirname(__file__) # <-- absolute dir the script is in
rel_path = "./input.txt"
abs_file_path = os.path.join(script_dir, rel_path)
input = open(abs_file_path).read()
count = 0
for i, char in enumerate(list(input), start=1):
if char == "(":

View File

@@ -1,4 +1,11 @@
input = open("input.txt").read()
import os
script_dir = os.path.dirname(__file__) # <-- absolute dir the script is in
rel_path = "./input.txt"
abs_file_path = os.path.join(script_dir, rel_path)
input = open(abs_file_path).read()
count = 0
for i, char in enumerate(list(input), start=1):
if char == "(":