Python を使用して 2 つの変数をファイルに書き込みたい。
この投稿に記載されている内容に基づいて、私は次のように書きました。
f.open('out','w')
f.write("%s %s\n" %str(int("0xFF",16)) %str(int("0xAA",16))
しかし、私はこのエラーが発生します:
Traceback (most recent call last):
File "process-python", line 8, in <module>
o.write("%s %s\n" %str(int("0xFF", 16)) %str(int("0xAA", 16)))
TypeError: not enough arguments for format string