Article directory
Python tutorial directory https://blog.csdn.net/weixin_50964512/article/details/130300085
Preface
Not just in Python, but in any language, file operations are very important because it allows large amounts of data to be stored locally for a long time.
This chapter is mainly about learning and sorting out common file operations in Python.
1. Basic file operations
For a file, there are three main steps:
- open a file
- Operation files
- close file