Answers for "os module in python documentation"

3

os module

>>> import os
>>> os.getcwd()      # Return the current working directory
'C:\Python39'
>>> os.chdir('/server/accesslogs')   # Change current working directory
>>> os.system('mkdir today')   # Run the command mkdir in the system shell
0
Posted by: Guest on May-14-2021

Code answers related to "os module in python documentation"

Python Answers by Framework

Browse Popular Code Answers by Language