Learn to Code via Tutorials on Repl.it!

← Back to all posts
How to Make Cool Art with Python Turtle
Barry123

Hi everyone and here's just a quick tutorial on how to create cool designs with Python Turtle in just a few lines of code!


Step 1:

Import the turtle module and create a turtle (in this case the turtle is called bob, but you can name the turtle whatever you want).


Step 2:

Add a for loop with some random turtle code like the ones listed above. You can find a list of turtle commands here.


Step 3:

Add some colors to your drawing. The code to set the color of bob to green is bob.color("green"). You may also use RGB: bob.color((0,255,0)). You can change the turtle's color as many times as you like. Change the background color this way:


Step 4:

Test out your code. If it doesn't look right try again with different values. Repeat the process until you have a perfect turtle drawing. Tip: make bob invisible with bob.hideturtle() if that looks better. He will still be able to draw.


Step 5:

Make the turtle draw faster. Setting the speed to the highest with bob.speed(0) will work, but sometimes it will still take a long time to draw. Putting the drawing code between bob.tracer(0) and bob.tracer(1) makes the whole thing really fast.

Great! Now you have a nice turtle drawing to stare at all day!

Voters
EliBartleyClyme
JoshuaLlewelly1
ColinOKeefe1
EnsoValle
AndrsOlalla
jyuvero007
MemeManHimself
E-Sheep
Barry123
Comments
hotnewtop
AricJoshua

These lines of code have greatly aided me in completing the python turtle painting. I'm a software student, and I really need to understand the code. cookie clicker

pipahaha

Your instructions are very detailed, I will follow along to see how the results! word counter online

Barry123

lol

GregoryStellar

First, you need to understand Turtle, which is a drawing board-like Python function that lets us tell the turtle to draw all over it! We can use functions like turtle.forward (…) and turtle.right (…) that can move the turtle. Commonly used methods for turtles are: Method Parameter Description
It is like a basic foundation in various sciences of plastic surgery here and cosmetic surgery, which takes the first step and then step by step!

Barry123

lol

JohnMartin13

These lines of codes help me a lot to complete the art of python turtle. I am a student of software and I really need to learn the code. The essaypro help me a lot in Learning code. They write easy and understand code for students, so they can understand it well.

Barry123

lol

MemeManHimself

amAzINg wOah

Barry123

Thanks!

MemeManHimself

@Barry123 np :D

k9chelsea2

noice