Deal With Python Directory | What Is Python Directory- Python Tutorial Help
What is Directory in Python? A directory or folder is a collection of files and sub directories. Python has the os module. which provides us with many useful methods to work with directories (and files as well). Get Current Directory Use command : >>>getcwd() Example: >>> import module >>>os.getcwd() Output: 'C:\\Program Files\\Py...' Use print() to escape extra backspace. Example: >>> print(os.getcwd()) Output: C:\Program Files\PyScripter Changing Directory We can change t