May 2019
Beginner
528 pages
29h 51m
English
The following table summarizes the various file-open modes for text files, including the modes for reading and writing we’ve introduced. The writing and appending modes create the file if it does not exist. The reading modes raise a FileNotFoundError if the file does not exist. Each text-file mode has a corresponding binary-file mode specified with b, as in 'rb' or 'wb+'. You’d use these modes, for example, if you were reading or writing binary files, such as images, audio, video, compressed ZIP files and many other popular custom file formats.

Here are ...
Read now
Unlock full access