When using the turtle module in Python, there are six different turtle shapes you can use to change the shape of your turtle. The list of turtle shapes includes the following shapes.
turtle_shapes_list = ["arrow","turtle","circle","square","triangle","classic"]
To change the shape of your turtle, call the shape() function.
import turtle
t = turtle.Turtle()
t.shape("turtle")
The turtle module in Python allows us to create graphics easily in our Python code.
We can use the turtle module to make all sorts of designs with Python. The thing that draws our designs is called a turtle, and we can change the shape of a turtle easily.
What are all of the shapes of a turtle that we can use in Python?
There are six turtle shapes you can use in Python. The list of turtle shapes includes the following shapes.
turtle_shapes_list = ["arrow","turtle","circle","square","triangle","classic"]
With this turtle shapes list, we can then change the shape of a turtle easily in Python by calling the shape() function.
Below is how to change the shape of a turtle with shape() in Python.
import turtle
t = turtle.Turtle()
t.shape("turtle")
How to Change the Shape of Turtle in Python
When working with the turtle module in Python, we can easily change the shape of the turtle.
To change the shape of your turtle in Python, use the shape() function and pass one of the six turtle shapes from above.
For example, if we want to change our turtle to a “turtle” shape, we pass “turtle” as shown in the following Python example.
import turtle
t = turtle.Turtle()
t.shape("turtle")
If we want to change the turtle shape to “circle”, we pass “circle” as shown below.
import turtle
t = turtle.Turtle()
t.shape("circle")
Then if you want to change the color of your turtle, you can change color using the color() function.
import turtle
t = turtle.Turtle()
t.shape("circle")
t.color("red")
Hopefully this article has been useful for you to learn about the turtle shapes list in Python.