Data commit
This commit is contained in:
parent
7387c8f97b
commit
cb5bb5e222
199093 changed files with 3378972 additions and 0 deletions
7
Task/Delete-a-file/Python/delete-a-file-1.py
Normal file
7
Task/Delete-a-file/Python/delete-a-file-1.py
Normal file
|
|
@ -0,0 +1,7 @@
|
|||
import os
|
||||
# current directory
|
||||
os.remove("output.txt")
|
||||
os.rmdir("docs")
|
||||
# root directory
|
||||
os.remove("/output.txt")
|
||||
os.rmdir("/docs")
|
||||
2
Task/Delete-a-file/Python/delete-a-file-2.py
Normal file
2
Task/Delete-a-file/Python/delete-a-file-2.py
Normal file
|
|
@ -0,0 +1,2 @@
|
|||
import shutil
|
||||
shutil.rmtree("docs")
|
||||
Loading…
Add table
Add a link
Reference in a new issue