how to add python list code example
Example 1: add list python
my_list = ['a', 'b', 'c']
my_list.append('e')
print(my_list)
# Output
#['a', 'b', 'c', 'e']
Example 2: how to add to a list python
a_list = [1,2,3]
a_list.append(4)
my_list = ['a', 'b', 'c']
my_list.append('e')
print(my_list)
# Output
#['a', 'b', 'c', 'e']
a_list = [1,2,3]
a_list.append(4)