Answers for "Check if file already existing"

0

Check if file already existing

import os.path

if os.path.exists('filename.txt'):
    print ("File exist")
else:
    print ("File not exist")
Posted by: Guest on April-27-2021

Code answers related to "Check if file already existing"

Python Answers by Framework

Browse Popular Code Answers by Language