• Courses
  • Tutorials
  • Jobs
  • Practice
  • Contests
June 30, 2022 |100.2K Views
Reading and Writing to text files in Python
  Share   Like
Description
Discussion

Python provides inbuilt functions for creating, writing, and reading files. There are two types of files that can be handled in python, normal text files and binary files (written in binary language, 0s, and 1s).


Text files: In this type of file, Each line of text is terminated with a special character called EOL (End of Line), which is the new line character (‘\n’) in python by default.


Binary files: In this type of file, there is no terminator for a line, and the data is stored after converting it into machine-understandable binary language.


Reading and Writing to text files in Python : https://www.geeksforgeeks.org/reading-writing-text-files-python/

Read More