Created
September 11, 2021 02:56
-
-
Save curious-username/b40261e1c6b60af2165d8f3a6dfb3cd1 to your computer and use it in GitHub Desktop.
recursively creating a folder
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import os | |
while True: | |
directory = input('Enter a folder name to create\n') | |
if directory == '': | |
break | |
else: | |
print(os.listdir()) | |
os.mkdir(directory) | |
print(os.listdir()) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment