eurofilename beforepart daypart '-monthpart '-yearpart afterpart get the fullabsolute file paths absworkingdir os path abspath('amerfilename os path join(absworkingdiramerfilenameeurofilename os path join(absworkingdireurofilenamerename the files print( 'renaming "{amerfilename}to "{eurofilename}'#shutil move(amerfilenameeurofilenameuncomment after testing store the concatenated string in variable named eurofilename thenpass the original filename in amerfilename and the new eurofilename variable to the shutil move(function to rename the file this program has the shutil move(call commented out and instead prints the filenames that will be renamed running the program like this first can let you double-check that the files are renamed correctly then you can uncomment the shutil move(call and run the program again to actually rename the files ideas for similar programs there are many other reasons you might want to rename large number of files to add prefix to the start of the filenamesuch as adding spam_ to rename eggs txt to spam_eggs txt to change filenames with european-style dates to american-style dates to remove the zeros from files such as spam txt projectbacking up folder into zip file say you're working on project whose files you keep in folder named :\alspythonbook you're worried about losing your workso you' like to create zip file "snapshotsof the entire folder you' like to keep different versionsso you want the zip file' filename to increment each time it is madefor examplealspythonbook_ zipalspythonbook_ zipalspythonbook_ zipand so on you could do this by handbut it is rather annoyingand you might accidentally misnumber the zip filesnames it would be much simpler to run program that does this boring task for you for this projectopen new file editor window and save it as backuptozip py step figure out the zip file' name the code for this program will be placed into function named backuptozip(this will make it easy to copy and paste the function organizing files