readable()
readable()
Returns boolean value True or False. Returns True if file is readable , otherwise False .
In file read mode ( r )
fob=open('data1.txt','r')
print(fob.readable()) # True
Using write mode
fob=open('data1.txt','w')
print(fob.readable()) # False
Using append mode
fob=open('data1.txt','a')
print(fob.readable()) # False
Using read and write
fob=open('data1.txt','+a')
print(fob.readable()) # True
writable() »
« File Append
File Write »
← Subscribe to our YouTube Channel here
This article is written by plus2net.com team.
https://www.plus2net.com
plus2net.com