Q. How can you write multiple lines to a file efficiently?
β
Correct Answer: (B)
writelines()
Explanation: writelines() writes a list of strings to a file without adding newline characters automatically.