Colors, Circles & Snowflakes
Fill shapes with color and draw honeycombs, planets and snowflakes.
Colors, Circles & Snowflakes π¨
Let's make our drawings shine!
πͺ Draw a planet
t.circle(50) draws a circle. Wrap it in begin_fill() and end_fill() to color it in:
import turtle
t = turtle.Turtle()
t.color("orange")
t.begin_fill()
t.circle(60)
t.end_fill()π A honeybee hexagon
Bees build their honeycomb out of hexagons: shapes with 6 sides. It's a super strong shape that uses very little wax! For 6 sides, turn 360 Γ· 6 = 60 degrees each time:
import turtle
t = turtle.Turtle()
t.color("goldenrod")
t.begin_fill()
for i in range(6):
t.forward(60)
t.left(60)
t.end_fill()π‘π§ Shape rule: to draw any shape, turn 360 divided by the number of sides.
βοΈ A snowflake
Real snowflakes almost always have 6 arms. One loop can draw them all:
import turtle
t = turtle.Turtle()
t.color("deepskyblue")
for arm in range(6):
t.forward(80)
t.backward(80)
t.left(60)π Colors to try
"red", "blue", "green", "purple", "gold", "pink", "deepskyblue", "forestgreen"
Challenge yourself: change the numbers and colors and make your own galaxy. Then press Share to show someone your drawing!
Type it yourself
Don't just read it β type the example from above into the box, press Run βΆ, and watch what happens. Typing it yourself is how it really sticks! Stuck? Tap Show example.
Press βΆ Run to see your code come to lifeβ¦