change directory in python 2.7 code example Example: change working directory python import os os.chdir(new_working_directory)