import shutil shutil.copyfile('index.py', 'ttt.py')