選択できるのは25トピックまでです。 トピックは、先頭が英数字で、英数字とダッシュ('-')を使用した35文字以内のものにしてください。

19 行
365B

  1. import itertools
  2. import re
  3. import sys
  4. from intcode import compute, parse
  5. def check(noun, verb):
  6. ns = parse(text)
  7. ns[1:3] = [noun, verb]
  8. list(compute(ns, 2))
  9. return ns[0]
  10. text = sys.stdin.read()
  11. print(check(12, 2))
  12. for noun, verb in itertools.product(range(100), repeat=2):
  13. if check(noun, verb) == 19690720:
  14. print(100 * noun + verb)