In an interview they asked me about Python with keyword implementation. I could not answer except its use in open
ing files and in lock
. Then they asked me why don't we close file in with open("x.txt") as f:
Can anyone tell about with
implementation and how does it behave differently for files and locks?