Skip to content
Advertisement

Tag: turtle-graphics

Spirograph Turtle Python

How can I play with a turtle and how can I use a turtle? I have trouble getting the thing to work as in the picture shown below (ignore the colors). I am trying to make that kind of shape. Here is the coding I have done so far. Answer Try changing your t_iterating function to this:

Draw faster circles with Python turtle

I have an exercise wherein I have to draw a lot of circles with Python turtle. I have set speed(0) and I am using: to draw circles. It takes so long. Is there any faster way? Answer You could draw fewer segments, so rather than 360 you go for 120: That will make your circle less smooth, but three times

python turtle loop

I am trying to create a looping square, and cannot figure out how to get my code to allow me to keep repeating the command of creating squares, times the number input, heres what I have currently. Answer You can use for i in range(count_int): to run a piece of code repeatedly given a repeat count in count_int:

How to create a subclass in python that is inherited from turtle Module

So, i’m trying to learn python and every time i post a question here it feels like giving in… I’m trying to make my own class of turtle.Turtle. Gives the Traceback: AttributeError: ‘TurtleGTX’ object has no attribute ‘_position’. Which I then learn is a “private vairable” which according to the offical python tutorial i can mangle/override in my subclass TurtleGTX.

Advertisement