After searching a bit and not finding an answer, here I am with my question.
The example given in the for loops chapter was this:
dog_breeds = [‘french_bulldog’, ‘dalmation’, ‘shihtzu’, ‘poodle’, ‘collie’]
for breed in dog_breeds:
Now, my question is, say we have a list containing names and ages of people, such as:
my_list = [‘Pam’, 22, ‘George’, 44, ‘Robert’, 35] and so on…
Now, can I use a for loop to loop through the ages (integers) and return the age values? If yes, then how do I do that ?