Question: Write a python script to: Check if the folders IT421, IT151, and IT620 exist. If they do not, create them in your folder. Use libraries:
Write a python script to: Check if the folders IT421, IT151, and IT620 exist. If they do not, create them in your folder. Use libraries: os, ex: os.mkdir() Then move the files that begin with ITx to the folder ITx where x is the class number. If the file already exists, rename it like the following example: IT421_1456991403.txt becomes IT421J456991403 (l).txt And, IT421J456991403 (l).txt becomes IT421_1456991403 (2).txt Note that if you do not have duplicates, copy a few into another folder and test your code. Write a python script to: For each folder, create a folder called old if it does not exist. Move all files older than 25 days into that folder. Apply the same renaming scheme as done in task 2
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
