Q. Predict the output:


L1 = [x ** 2 for x in range(10) if x % 3 == 0]

L2 = L1

L1. append (len(L1))

print (L1)

print(L2)

L2.remove(len(L2) - 1)

print (L1)


Answer =

Output:-

[0, 9, 36, 81, 4]
[0, 9, 36, 81, 4]
[0, 9, 36, 81]
>>>

Post a Comment

You can help us by Clicking on ads. ^_^
Please do not send spam comment : )

Previous Post Next Post