mirror of
https://github.com/thib8956/advent-of-code.git
synced 2025-08-24 08:21:57 +00:00
make 2020 compatible with run.py
This commit is contained in:
@@ -27,7 +27,8 @@ def step(grid, rules):
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
with open("input.txt") as infile:
|
||||
import sys
|
||||
with open(sys.argv[1]) as infile:
|
||||
grid = list("".join(infile.read().splitlines()))
|
||||
print("Part 1 ", main(grid, rules=part1_rules))
|
||||
print("Part 2 ", main(grid, rules=part2_rules))
|
||||
|
Reference in New Issue
Block a user