r/Python • • Oct 04 '21

Tutorial I created this simple python program that will organise files into different folders according to file type

https://youtu.be/BgLVNSyK0HY
0 Upvotes

1 comment sorted by

1

u/uYhr Oct 04 '21

Nice.

Maybe:

If not (path exists): create path

copy file

would be more appropriate.

Also, as an refinement, you may add function that discoveres LAST dot in the file name, because there may be more than one dot, and only last denotes extension.

Again, nice introduction to shutil.