Vidyalelo
Python · Q9

Files Handling in Python

Programming · Python · question 9

Q9

How can you create a new file in Python if it doesn't exist?

A.
By using the 'x' mode when opening the file
Answer
B.
By using the 'create' keyword
C.
By using the new() function
D.
By using the 'c' mode when opening the file

Answer: Option A

Solution

Answer: Option A
No explanation is given for this question Let's Discuss on Board