--:--









Quiz for Binary file operations

Course: C++ Language | Subject: Unit 12 | Topic: File Handling



Logo

Q1: Which mode is used to open a file in binary mode?

Logo

Q2: Which function is used to write binary data to a file?

Logo

Q3: Which function is used to read binary data from a file?

Logo

Q4: What does the function write() require as arguments?

Logo

Q5: What type of pointer is passed to read() function?

Logo

Q6: How do you open a file named "data.bin" for binary output?

Logo

Q7: What is the return type of write() function?

Logo

Q8: Can binary files be edited directly with a text editor?

Logo

Q9: Which of the following is NOT true about binary files?

Logo

Q10: Which function moves the get pointer to a specified location?

Logo

Q11: Which function moves the put pointer to a specified location?

Logo

Q12: Which function tells the current position of the get pointer?

Logo

Q13: Which function tells the current position of the put pointer?

Logo

Q14: What happens if you try to read more bytes than available in a binary file?

Logo

Q15: Which flag combination opens a binary file for both input and output?

Logo

Q16: How can you check if a binary file stream is open?

Logo

Q17: What is the typical size of data chunk used with read/write?

Logo

Q18: Why use binary files over text files?

Are you ready to start test? Set your time limit