venture of iit bombay vjti alumni close opend file fo close(the above method would create foo txt file and would write given content in that file and finally it would close that file if you would open this fileit would have following content python is great language yeah its great!the read(method the read(method reads string from an open file it is important to note that python strings can have binary data apart from text data syntax fileobject read([count])herepassed parameter is the number of bytes to be read from the opened file this method starts reading from the beginning of the file and if count is missingthen it tries to read as much as possiblemaybe until the end of file