?
What will be the output of the following Python code?
What will be the output of the following Python code?
def foo(i, x=[]):
x.append(i)
return x
for i in range(3):
print(foo(i))
def foo(i, x=[]):
x.append(i)
return x
for i in range(3):
print(foo(i))
Join the Discussion
Login to post a comment or share your explanation.
Login