MULTIPLE CHOICE QUESTIONS AND ANSWERS
  1. In order, the three-step process of using a file in a C++ program involves:

    • Name the file, open the file, and delete the file

    • Insert a diskette, open a file, and remove the diskette

    • Open the existing file, read/write data, close the file

    • none of these

    • Create the file contents, close the file, and name the file

      Answer: (c)

  2. True/False: The maximum number of file stream objects can be declared are two.

    Answer: False

  3. True/False: A file pointer always contains the address of the file.

    Answer: False

  4. True/False: Binary files store floating-point values more accurately and compactly than the text files.

    Answer: False

  5. True/False A stream may be connected to more than one file at a time.

    Answer: False ...

Get Object Oriented Programming with C++, Second Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.