-
Notifications
You must be signed in to change notification settings - Fork 13
/
python_logo.py
101 lines (81 loc) · 1.3 KB
/
python_logo.py
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
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
import turtle
t = turtle.Turtle()
s = turtle.Screen()
s.bgcolor("black")
t.speed(10)
t.pensize(2)
t.pencolor("white")
def s_curve():
for i in range(90):
t.left(1)
t.forward(1)
def r_curve():
for i in range(90):
t.right(1)
t.forward(1)
def l_curve():
s_curve()
t.forward(80)
s_curve()
def l_curve1():
s_curve()
t.forward(90)
s_curve()
def half():
t.forward(50)
s_curve()
t.forward(90)
l_curve()
t.forward(40)
t.left(90)
t.forward(80)
t.right(90)
t.forward(10)
t.right(90)
t.forward(120) #on test
l_curve1()
t.forward(30)
t.left(90)
t.forward(50)
r_curve()
t.forward(40)
t.end_fill()
def get_pos():
t.penup()
t.forward(20)
t.right(90)
t.forward(10)
t.right(90)
t.pendown()
def eye():
t.penup()
t.right(90)
t.forward(160)
t.left(90)
t.forward(70)
t.pencolor("black")
t.dot(35)
def sec_dot():
t.left(90)
t.penup()
t.forward(310)
t.left(90)
t.forward(120)
t.pendown()
t.dot(35)
t.fillcolor("#306998")
t.begin_fill()
half()
t.end_fill()
get_pos()
t.fillcolor("#FFD43B")
t.begin_fill()
half()
t.end_fill()
eye()
sec_dot()
def pause():
t.speed(2)
for i in range(100):
t.left(90)
pause()