for loop how to work code example Example: for loop fruits = ['apple', 'orange', 'peach'] for fruit in fruits: print(fruit)