In this challenge we will use Python Turtle to draw regular polygons including:
- An equilateral triangle
- A square
- A pentagon
- An hexagon
- etc.
Did you know?
In Euclidean geometry, a regular polygon is a polygon that is equiangular (all angles are equal in measure) and equilateral (all sides have the same length). Regular polygons may be convex or star.
Convex Regular Polygons
Looking at the following three polygons, we can work out a formula to calculate the external angle of a convex regular polygon based on its number of sides.


Python Code
Based on this formula we have implanted a function called drawPolygon() which takes one parameter called numberOfSides. This function will draw the corresponding convex regular polygon on screen.
Star Regular Polygons

Your challenge consists of coding a similar function, called drawStar(), used to draw star regular polygons on the screen. This function will take two parameters called numberOfSides and multiplier.
This time we will use a different formula to calculate the exterior angle:
You can test your code with the following parameter values:
| Star # | Number of Sides | Multiplier |
| #1 | 5 | 2 |
| #2 | 8 | 3 |
| #3 | 9 | 4 |
| #4 | 10 | 3 |
| #5 | 12 | 5 |
In this challenge we are going to create a cat’s age convertor find out how old a cat is in “human years”. This is very useful to understand more about cats and the care they need and to find out at what stage of life a cat is.
“Guess how many sweets are in the jar” is a fundraising game. A large see-through jar is filled with a carefully counted number of sweets. People then try to guess how many sweets are in the jar. Each contestant has to donate a small amount of money to have a go. Guesses are recorded (name + guess). At the end of the game, the nearest guesser wins the content of the jar.
In mathematics, one of the most interesting number patterns is Pascal’s Triangle. It is named after Blaise Pascal (1623 – 1662), a famous French Mathematician and Philosopher.




In geometry, the golden angle is the smaller of the two angles created by sectioning the circumference of a circle according to the golden ratio.





In this challenge we will write several procedures to graph different mathematical equations on screen using Python Turtle.
On the Python trinket used below the turtle screen is 400 pixels wide by 400 pixels high.

