Don’t you also have to keep in mind how often you flush outputs/how you buffer? Encoding? Handle EOF correctly?
Not saying it’s hard but also it’s not 100% covered by what you said.
Not saying it’s hard but also it’s not 100% covered by what you said.
Generally, Python does the right thing by default for scripting use: line buffered, system encoding, EOF handled naturally by the iterator protocol.