Pelokalan
Python ID
id en
Masuk
Proyek
library__io.po Berkas proyek · python-docs-id-3.14 · Bahasa Indonesia
Modul PO Hanya lihat
Teks sumber — English
Terjemahan — Bahasa Indonesia
When reading input from the stream, if *newline* is ``None``, :term:`universal newlines` mode is enabled. Lines in the input can end in ``'\n'``, ``'\r'``, or ``'\r\n'``, and these are translated into ``'\n'`` before being returned to the caller. If *newline* is ``''``, universal newlines mode is enabled, but line endings are returned to the caller untranslated. If *newline* has any of the other legal values, input lines are only terminated by the given string, and the line ending is returned to the caller untranslated.
When writing output to the stream, if *newline* is ``None``, any ``'\n'`` characters written are translated to the system default line separator, :data:`os.linesep`. If *newline* is ``''`` or ``'\n'``, no translation takes place. If *newline* is any of the other legal values, any ``'\n'`` characters written are translated to the given string.
Saat menulis keluaran ke aliran *stream*, jika *newline* adalah ``None``, setiap karakter ``'\n'`` yang ditulis diterjemahkan ke pemisah garis bawaan sistem, :data:`os.linesep`. Jika *newline* adalah ``''`` atau ``'\n'``, tidak ada terjemahan yang terjadi. Jika *newline* adalah salah satu dari nilai legal lainnya, setiap karakter ``'\n'`` yang ditulis diterjemahkan ke string yang diberikan.