animals = [‘pig‘,‘dog‘,‘cat‘] for animal in animals: print(‘A ‘ + animal + "would make a great pet") print(‘Any of these animals would make a great pet!‘)
pythOn for循环
原文:https://www.cnblogs.com/yhzhao1/p/13321648.html