What is file mode?Describe various file mode available

Subject Object Oriented Programming
NU Year Set: 6.(b) Marks: 5 Year: 2010

A file mode describes how a file is to be used, to read, to write to append etc. When you associate a stream with a file, either by initializing a file stream object with a file name or by using open() method, you can provide a second argument specifying the file mode.

e.g. stream_object.open("filename",filemode);

Following is the list of filemodes available in C++

Login to post your comment.