The append Method in Python: Adding Elements to a List

The append method adds an element to the end of a list. It modifies the original list and returns None.

append(x)

  • x: object to be added to the list.
my_list = ["a", "b", "c"]
my_list.append("d")  # my_list becomes ["a", "b", "c", "d"]
my_list.append(3)    # my_list becomes ["a", "b", "c", "d", 3]

To add multiple elements, use extend().