Rectangle(color="pink")

# Set up lists
strings = ["lollipop", "unicorn", "rainbow"]
y_positions = [30, 50, 70]
loopList = range(len(strings))  # Explore exactly what is happening here!

# Run animation
for i in loopList:
    with animation(duration=1):
        Text(strings[i], x=50, y=y_positions[i])

For Loop Example 4

by jamie

Created 5 years, 9 months ago.