to european-style dates say your boss emails you thousands of files with american-style dates (mm-dd- yin their names and needs them renamed to europeanstyle dates (dd-mm- ythis boring task could take all day to do by handlet' write program to do it instead here' what the program does it searches all the filenames in the current working directory for american-style dates when one is foundit renames the file with the month and day swapped to make it european-style this means the code will need to do the following create regex that can identify the text pattern of american-style dates call os listdir(to find all the files in the working directory loop over each filenameusing the regex to check whether it has date if it has daterename the file with shutil move(for this projectopen new file editor window and save your code as renamedates py step create regex for american-style dates the first part of the program will need to import the necessary modules and create regex that can identify mm-dd- dates the to-do comments will remind you what' left to write in this program typing them as todo makes them easy to find using mu editor' ctrl - find feature make your code look like the following#python renamedates py renames filenames with american mm-dd-yyyy date format to european dd-mm-yyyy import shutilosre create regex that matches files with the american date format datepattern re compile( """^*?all text before the date (( | )?\ )one or two digits for the month (( | | | )?\ )one or two digits for the day (( | )\ \dfour digits for the year *?)all text after the date """re verbosetodoloop over the files in the working directory todoskip files without date