animals = ['cat', 'dog', 'rabbit', 'horse'] # get the index of 'dog' index = animals.index('dog') print(index) # Output: 1 1