Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PYTHON

Python Removing Directory or File

>>> os.listdir()
['new_one', 'old.txt']

>>> os.remove('old.txt')
>>> os.listdir()
['new_one']

>>> os.rmdir('new_one')
>>> os.listdir()
[]
 
PREVIOUS NEXT
Tagged: #Python #Removing #Directory #File
ADD COMMENT
Topic
Name
7+8 =