Source: thenewstack.io

Python for Beginners: Lists

Category: Data, Ubuntu, apple

Our Python for beginners tutorial continues, so let the celebratory “Huzzahs!” We’re going to continue building on those tutorials and doing so in such a way that anyone can follow.

That script would look like: #Define our color variable as a list color = ['blue','green','red','yellow']

#Print out both variables print (color,fruit, color, fruit, color, fruit, color, fruit)

#Define our fruit variable as a list fruit = ['blueberry','apple','cherry','banana']

Related Articles