How to Add an Item to End of List in Python


In this example, we will learn how to add an item to the end of the list in Python.

Source Code

my_list = ['a', 'b', 'c', 'd', 'e']
my_list.append('f')
print(my_list)

Output:

['a', 'b', 'c', 'd', 'e', 'f']
Subscribe
Notify of
guest
0 Comments
Inline Feedbacks
View all comments