CBSE Class 12 Computer Science Question 12 of 43

Practice Paper — Question 12

Back to all questions
12
Question

Question 12

What is the use of "w" in file handling?

Answer

In file handling, the "w" mode is used to open a file for writing. If the file exists, it will be overwritten. If the file does not exist, a new file will be created with the specified name.