class Cats: def __init__(self, name, colour, age, alive): self.name = name self.colour = colour self.age = age self.alive = alive catOne = Cats("Tiddles", "Black", 7, True) catTwo = Cats("Arnold", "White", 13, False) #print the name and age of a cat print(catOne.name, catOne.age) print() #which cat is older? if catOne.age > catTwo.age: print(catOne.name + " is older than " + catTwo.name) elif catOne.age < catTwo.age: print(catTwo.name + " is older than " + catOne.name) else: print(catOne.name + " and " + catTwo.name + " are the same age.") print() print("Next, an array of cats. Press Enter to continue.") input() #Add a cat catThree = Cats("Bonzo", "Black", 2, True) #create an array of 3 cats - you could add as many as you wanted here catArray = [catOne, catTwo, catThree] #which cats are alive? for theCat in catArray: if theCat.alive == True: print(theCat.name + " is alive") else: print(theCat.name + " is an ex-cat. It has ceased to purr.")