Output: Scope and Mutation
Interview insights are lockedSee how often this is asked and which companies asked it with Buncho Pro.What is the output of each snippet?
# A
x = 10
def test():
x = 20
test()
print(x)
# B
x = [1, 2, 3]
def test(a):
a += [4]
test(x)
print(x)