aoc2019/day09.py
Stefan Harmuth fbffd6e4fd day09
2021-11-27 19:46:55 +01:00

22 lines
483 B
Python

from aoc import AOCDay
from typing import Any
import intcode
class Day(AOCDay):
test_solutions_p1 = []
test_solutions_p2 = []
def part1(self) -> Any:
comp = intcode.IntCode(self.getInputAsArraySplit(",", int))
comp.addInput(1)
comp.run()
return comp.getOutput()
def part2(self) -> Any:
comp = intcode.IntCode(self.getInputAsArraySplit(",", int))
comp.addInput(2)
comp.run()
return comp.getOutput()