python list in list append code example
Example 1: add item to list python
list.append(item)
Example 2: append to lists python
list = ['a', 'b', 'c', 'd']
print list[1:-1] ## ['b', 'c']
list[0:2] = 'z' ## replace ['a', 'b'] with ['z']
print list ## ['z', 'c', 'd']