Click an option to check whether your answer is correct.
The correct expression to check if the file 'C:\Sample.txt' exists and is also a regular file is:
os.path.isfile("C:\Sample.txt")
So, the correct answer is: os.path.isfile("C:\Sample.txt")
Explore more questions from similar topics.
Share this MCQ with your friends or study group.