Using Lists for Ordered Collections in Python


Store multiple items in a single variable.

Source Code

fruits = ["apple", "banana", "cherry"]
print(fruits[0])  # Access the first item
Subscribe
Notify of
guest
0 Comments
Inline Feedbacks
View all comments