Files and Directories again

Let’s continue writing to file that was created in the previous post. In the code snippet above, Line number 1: The file path is mentioned in the __file__ variable. Line number 3: This code represents how to open the file and write the file. Line number 5: Writing file with few more data. Line numberContinue reading “Files and Directories again”

Files and Directories

Python provides functions to write / read files and operations like reading contents from the directory. These functions play a trivial role as most of the programs involves reading files or directories. Let’s discuss few functions related to this. File Object – First step to read / write files in Python is using File object.Continue reading “Files and Directories”

Design a site like this with WordPress.com
Get started