Practical Recipes for Working With Files in Python (Summary)
You now know how to use Python to perform the most common operations on files and groups of files. You’ve learned about the different built-in modules used to read, find, and manipulate them.
You’re now equipped to use Python to:
- Get directory contents and file properties
- Create directories and directory trees
- Find patterns in filenames
- Create temporary files and directories
- Move, rename, copy, and delete files or directories
- Read and extract data from different types of archives
- Read multiple files simultaneously using
Congratulations, you made it to the end of the course! What’s your #1 takeaway or favorite thing you learned? How are you going to put your newfound skills to use? Leave a comment in the discussion section and let us know.
00:00 Over the course of this lesson, you’ve really learned a heck of a lot about working with files in Python. You can now create, modify and delete all kinds of files, from temporary files to normal files, to directories, to ZIP and TAR archives.
You can also copy, move, or rename files and directories of various kinds. You can traverse directory trees, you can match patterns, you can get file properties, and you can open multiple files at the same time using the
Become a Member to join the conversation.