Step 6 – Getting clever with colours
There are some smart things we can do with colours and turtles.
- Change your code by removing the begin_fill() and end_fill() lines
- Run the code and see what this does
The turtle can draw lines without colouring anything in
- Delete the last right(90) and forward(120) lines
- Run the code and see what this does
This should create a shape that's not finished. It should look like the screenshot
- Now add back in the begin_fill() and end_fill() lines
- Run the code and see what this does now
The shape fills in even though you haven't finished it off. That's interesting (and quite useful).
Now try this:
- Change your code to match the screenshot
This creates just a two sided shape.
- Run the code and see what this does now
The fill commands have some interesting ways of working.
All the colours
Here's a set of colour names that the Python turtle knows.
Be careful when you type the names of colours. Some of them are quite tricky to spell!