Activity 1 - Drawing a square
Kudos! You helped Alex draw a line! Now let’s step it up and help Alex draw a square. A square is one of the simplest and most familiar shapes in geometry.A square has four sides and they are exactly the same length. When we say “angle,” we mean the space between two sides where they meet. In a square, all four angles are the same too.
The turtle needs to turn 90 degrees 4 times and move the exact number of steps each time to create a square.
Here’s the trick: the sum of the angles around a point (like where you turn) is always 360 degrees. If you divide 360 degrees by the number of turns you need to make (which is 4 for a square), you’ll get the angle you need to turn. So, 360 degrees ÷ 4 turns = 90 degrees per turn.
To draw a square, we need to follow these steps:
- Go forward for 50 steps
- Turn left by 90 degrees
- Go forward for 50 steps
- Turn left by 90 degrees
- Go forward for 50 steps
- Turn left by 90 degrees
- Go forward for 50 steps
Remember to use turtle.forward()
to draw lines. To turn 90 degrees left, you need to pass 90
as the argument to the turtle.left()
method:
turtle.left(90)