a = [1, 2, 3]print(id(a)) a = [4, 5, 6]print(id(a)) a[:] = [7, 8, 9]print(id(a))
Standard input is empty
47713454781832 47713454783560 47713454783560
The brand new service which powers Ideone!
Widget for compiling and running the source code in a web browser!