elements in list python code example
Example 1: python lists
thislist = ["apple", "banana", "cherry"]
print(thislist[1])
Example 2: python lists
fruits = ['apple', 'banana', 'mango', 'cherry']
for fruit in fruits:
print(fruit)
thislist = ["apple", "banana", "cherry"]
print(thislist[1])
fruits = ['apple', 'banana', 'mango', 'cherry']
for fruit in fruits:
print(fruit)