how to get current directory in python 3 code example Example: get diroctary in python import os cwd = os.getcwd() print(cwd)