Computer Science, asked by pandithariji2741, 9 months ago

What gets printed with given code ?
f = None
for i in range (5):
with open("data.txt", "w") as f:
if i > 2:
break
print f.closed

Answers

Answered by Anonymous
2

With the given cod, on execution a True statement will get printed.

  • The given code is the code of Python language. The code also uses various syntax.
  • When used with open file, the WITH statement guarantees that when the with block will exit, the file object will get closed.
  • Thus, the code on execution will give a true statement.
Answered by sanjotdhumal09
0

Explanation:

it is of python language

looping statement

answer true statement

Similar questions