Q. How to open a file for writing in binary mode?
β
Correct Answer: (A)
open('file', 'wb')
Explanation: 'wb' mode opens a file for writing binary data.