Q. What will be the output of the following Python code?
Code:def foo():
try:
return 1
finally:
return 2
k = foo()
print(k)
β
Correct Answer: (B)
2
def foo():
try:
return 1
finally:
return 2
k = foo()
print(k)
You must be Logged in to update hint/solution