-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathmorocco.py
More file actions
41 lines (29 loc) · 799 Bytes
/
morocco.py
File metadata and controls
41 lines (29 loc) · 799 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
# made with love by hlnaji
import turtle
def draw_star(size, star_color):
hlnaji = turtle.Turtle()
hlnaji.shape("turtle")
hlnaji.color(star_color)
hlnaji.speed(1)
hlnaji.width(9)
hlnaji.goto(-150, 0)
for _ in range(5):
hlnaji.forward(size)
hlnaji.right(180 * 4 / 5)
hlnaji.ht()
def draw_outline(size, star_color):
hlnaji = turtle.Turtle()
hlnaji.shape("turtle")
hlnaji.color(star_color)
hlnaji.speed(1)
hlnaji.width(12)
hlnaji.goto(-150, 0)
for _ in range(5):
hlnaji.forward(size)
hlnaji.right(180 * 4 / 5)
hlnaji.ht()
window = turtle.Screen()
window.bgcolor((193/255, 39/255, 45/255))
draw_outline(250, (1/255, 1/255, 1/255))
draw_star(250, (0/255, 98/255, 51/255))
window.exitonclick()