Python for Beginners, Python Tutorials, File Handling in Hindi, File Handling Tutorials, How to Read Data from File in Hindi, File Handling in Python, Reading Data from Files, Python
This is the new series in which we are going to focus on File Handling. All the functions used for
handling a file are covered in this series. Here, we are going to see how we can perform
manipulation with a file. This video is going to be all about the second function used for
handling a file that is read() function and what are the different methods of read() function are
covered with its implementation.
Using the read() function we can read the data present in the existing file. Firstly we need to open
the file in the read “r” mode. For this use :
var_name = open (“File_name” , “r”)
1) var_name.read() : Using this function we are able to read the complete content present in the
file.
2) var_name.read(6): Using this function we are able to read specific characters. Here we can read
6 characters including white space.
3) var_name.readline(): Using this function we are able to read only a single line from the overall content available in the text file.
4) var_name.readlines(): Using this function we are able to read all / multiple lines from the overall content available in the text file.
Do practice this!!
And let us know your suggestions, queries, and reviews!
Happy Programming :)
-----------------------------------------------------------------------------------------------------------------------------------
If you have missed anything regarding the python, surf through these links below:
Write data in File in Python: • How to Write Data in File #1 | File H...
Check Button Using Tkinter: • How to Create Check Button Using Tkin...
Create Radio Button Using Tkinter: • How to Create Radio Button using Tkin...
Create ListBox Using Tkinter: • How to create ListBox using Tkinter #...
Multiple Button in Frame Using Tkinter: • Create Multiple Buttons in Frame Usin...
Add Label & Entry Box Using Tkinter: • How to Add Label and Entry Box in Tki...
Arc On Canvas Using Tkinter: • How to Draw Arc on Canvas Using Tkint...
Create Message Box Using Tkinter: • How to Create Message Box using Tkint...
Create Button using Tkinter: • How to Create Button using Tkinter #2...
--------------------------------------------------------------------------------------------------------------------------------------
You’ll also find us here!!
Website: https://sdpguruji.in/
Play Store App: https://play.google.com/store/apps/de...
Instagram: / sdpguruji
Facebook: / sdp.guruji.3
LinkedIn: / sdpguruji
Telegram: https://t.me/sdpguruji
--------------------------------------------------------------------------------------------------------------------------------------
For more such informative Python videos,
color the thumbs up button blue, share the videos, and yes don’t forget to hit the subscribe button and press the bell icon for remainders.
Stay Tuned!!!
#sdpguruji
#sdp
#filehandling
#read
#file
#readdata
#readdatainfile
#textfile
#sdpgurujipython
#pythonsdpguruji
Смотрите видео How to Read Data from a Text File #2 | File Handling in Python | Reading Data from File | SDP Guruji онлайн без регистрации, длительностью часов минут секунд в хорошем качестве. Это видео добавил пользователь SDP Guruji 12 Ноябрь 2020, не забудьте поделиться им ссылкой с друзьями и знакомыми, на нашем сайте его посмотрели 115 раз и оно понравилось 31 людям.