Python Program to Draw Heart Using Turtle
#Python Program to Draw Heart Using Turtle
import turtle
wn = turtle.Screen()
wn.setup(width=400, height=400)
red = turtle.Turtle() # Assigning "Red" as name of the turtle
def curve(): # Method to draw curve
for i in range(200): # To draw the curve step by step
red.right(1)
red.forward(1)
def heart(): # Method to draw full Heart
red.fillcolor('red')
red.begin_fill()
red.left(140)
red.forward(113)
curve() # Left Curve
red.left(120)
curve() # Right Curve
red.forward(112)
red.end_fill()
heart()
red.ht() # Hiding Turtle
turtle.done()
Output:
About The Author
I have more than 6 years of experience in the IT industry, and I have built a solid foundation in the creation and upkeep of online applications. I have constantly shown strong work ethics, self-motivation, and an aptitude for learning quickly throughout my career.