Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PYTHON

Lists and for loops

for number in range(20):
    if number % 3 == 0:
        print(number)

for fruit in ["banana", "apple", "quince"]:
    print("I like to eat " + fruit + "s!")
Source by openbookproject.net #
 
PREVIOUS NEXT
Tagged: #Lists #loops
ADD COMMENT
Topic
Name
3+9 =