ios::truncate is not a file opening mode - File Handling

Q.  Which of the following is not a file opening mode ____ .
- Published on 19 Jul 15

a. ios::ate
b. ios::nocreate
c. ios::noreplace
d. ios::truncate

ANSWER: ios::truncate
 

    Discussion

  • Brijesh   -Posted on 13 Oct 15
    ios::truncate is not a file opening mode. In actual ios::trunk mode is available. If FileName already exists, its content is destroyed and the file becomes empty and works as new file.

Post your comment / Share knowledge


Enter the code shown above:

(Note: If you cannot read the numbers in the above image, reload the page to generate a new one.)