How to create new directory in Python

1 Answer

0 votes
import os 

os.mkdir('temp') 

dir_list = os.listdir()

print(dir_list)
                  
                  

'''
run:

['temp', 'main.py']

'''

 



answered Feb 22, 2023 by avibootz

Related questions

1 answer 179 views
1 answer 137 views
1 answer 129 views
129 views asked Jun 5, 2019 by avibootz
...