How to Access List Items with Index Number in Python


In this example we will show how to access the list items by referring to the index number in Python.

Source Code

my_list = ['a', 'b', 'c', 'd', 'e']
print(my_list[2])

Output:

c
Subscribe
Notify of
guest
0 Comments
Inline Feedbacks
View all comments