From 0f3c8384988b4daecc6580ca6bda58efdb41419e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jure=20=C5=A0orn?= Date: Wed, 30 Jan 2019 06:57:01 +0100 Subject: [PATCH] File --- README.md | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/README.md b/README.md index 579e000..8684755 100644 --- a/README.md +++ b/README.md @@ -846,13 +846,15 @@ while True: ``` #### Modes: -* `'r'` - open for reading (default) -* `'w'` - open for writing, erasing the file first -* `'x'` - open for exclusive creation, failing if the file already exists -* `'a'` - open for writing, appending to the end of the file if it exists -* `'b'` - binary mode -* `'t'` - text mode (default) -* `'+'` - open a disk file for updating (reading and writing) +* `'r'` - read (default) +* `'w'` - write (truncate) +* `'x'` - write or fail if the file already exists +* `'a'` - append +* `'w+'` - read and write (truncate) +* `'r+'` - read and write from begining +* `'a+'` - read and write from end +* `'b'` - binary mode +* `'t'` - text mode (default) #### Read Text from File: ```python