Skip to content

Instantly share code, notes, and snippets.

@jai-dewani
Last active February 6, 2023 18:11
Show Gist options
  • Save jai-dewani/8701a78c77f9b30585fa7b74bd03fe58 to your computer and use it in GitHub Desktop.
Save jai-dewani/8701a78c77f9b30585fa7b74bd03fe58 to your computer and use it in GitHub Desktop.
A python script that created a pride flag using turtle
from turtle import *
colors = ["red","orange","yellow","green","blue","purple"]
def move(x):
forward(x)
right(90)
def strip():
pendown()
begin_fill()
move(800)
move(100)
move(800)
move(100)
end_fill()
penup()
if __init__=="__main__"
speed(8)
penup()
goto(-400,300)
hideturtle()
for col in colors:
color(col,col)
strip()
right(90)
forward(100)
left(90)
input()
@khurchla
Copy link

khurchla commented Feb 6, 2023

this is awesome! I think I'll use this during a fun team exercise—thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment