Object Oriented Programming20765 marksRead/Write from File
Which function can be used for reading and writing object? Define briefly. Write a program that reads values of two objects of students class (assume data members are id, name, and level) and display the data in monitor.
Which function can be used for reading and writing object? Define briefly. Write a program that reads values of two objects of students class (assume data members are id, name, and level) and display the data in monitor. [5]
In C++, the read() and write() member functions of file stream classes are used for reading and writing objects (binary data) to/from files or streams. Used to write an object (block of bytes) to a stream. Syntax: - (char ) casts the object address to a character pointer - sizeof(objectName) dete...