I wanted to know how do append function work for sublists of lists in Python
If we create a list as:
a = [[]]*4
and append as:
a[0].append(10)
The output of printing a was:
[[10],[10],[10,[10]]
Why does 10 get copied in all four sublists while it should just for the first one??? i.e.
[[10],[],[],[]]