function that retrieves an element from a list python code example
Example 1: get an item out of a list python
#to get the LAST item out of a list:
things = ["apple", "book", 3, ["another list", 85], "orange"]
last = things.pop()
print(last)
#it should output "orange"
Example 2: python lists
fruits = ['apple', 'banana', 'mango', 'cherry']
for fruit in fruits:
print(fruit)