No, it is not necessary that a file is created in text mode must always be opened in text mode, it can also be opened in binary mode, for subsequent operations. Binary or text depends upon the content storage mode, a file with extension .txt can also be a binary file.
Ad
Chapter - 13: File Input-Output
Is it necessary that a file created in text mode must always be opened in text mode for subsequent operations?
Ad
Ad