When working with binary files in C, what is the significance of the 'b' character in the mode string?

  • It denotes the file is binary, and data is stored as a series of 0s and 1s.
  • It indicates the file is a backup copy.
  • It represents the file is a text file.
  • It specifies the file is in compressed format.
In C, the 'b' character in the mode string indicates that the file is opened in binary mode. In this mode, data is read or written in its raw binary form, without any character encoding or translation. This is essential when working with binary files like images or executable files.
Add your answer
Loading...

Leave a comment

Your email address will not be published. Required fields are marked *