Skip to content

Instantly share code, notes, and snippets.

@Raghavagr
Created February 14, 2021 18:53
t = turtle.Turtle()
t.color("red","blue")
wn = turtle.Screen()
wn.title("Crazy_Tech turtle tutorial")
wn.bgcolor("black")
t.speed(1) #adjust the speed of turtle
t.begin_fill()
t.fillcolor("yellow")
#draw square shape, assuming side of 120px
for i in range(4):
t.forward(120)
t.left(90)
t.end_fill()
t.hideturtle()
#to stop the screen to display
turtle.mainloop()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment