FreeKB - Python For loop
Python - For loop

Let's say you have an array of fruit.

fruits = ["apple", "banana", "orange", "grapes"]

 

You can loop through the array.

for x in fruits:
  print(x)

 

This will print each fruit.

apple
banana
orange
grapes

 



Add a Comment




We will never share your name or email with anyone. Enter your email if you would like to be notified when we respond to your comment.




Please enter 61f76 in the box below so that we can be sure you are a human.




Comments

Web design by yours truely - me, myself, and I   |   jeremy.canfield@freekb.net   |