In C, if you want to ensure that all the data written to a file is physically stored, you can use the ______ function.
- fwrite()
- fflush()
- fseek()
- fsync()
The correct option is b) fflush(). This function flushes the output buffer, ensuring that all data is physically stored in the file.
Loading...
Related Quiz
- A pointer in C holds the ________ of a variable.
- In C, a ________ is used to store a sequence of characters.
- What happens when you perform pointer arithmetic on a pointer to a data type other than 'char'?
- In C, what is the result of the expression (5 & 3)?
- In a graphics rendering engine, you need to apply different transformations (e.g., rotate, scale, translate) to objects. How can function pointers be used to simplify the implementation?