What Will Be The Output Of The Following Python Codep Pre #1035
What will be the output of the following Python code?</p> <pre><code class="language-python" line="1"> fo = open("foo.txt", "wb") print "Name of the file: ", fo.name fo.flush() fo.close() </code></pre>
This multiple choice question (MCQ) is related to the book/course gs gs109 Python. It can also be found in gs gs109 Python Files - Python Files - Quiz No.3.
What will be the output of the following Python code?
fo = open("foo.txt", "wb") print "Name of the file: ", fo.name fo.flush() fo.close()
Compilation Error
Runtime Error
No Output
Flushes the file when closing them