How to Access Elements of an Array in Python


In this example, we will learn how to access the elements of an array by referring to the index number in Python.

Source Code

letter = ['a', 'b', 'c', 'd']
letter_2 = letter[1]
print(letter_2)

Output:

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