Empty the List in Python

Source code :

list1 = [1, 2, 3]
list2 = lst1
del lst1[:]
print(list2)

Output :

[]

Output :


                

Comments :