-
Notifications
You must be signed in to change notification settings - Fork 1
/
tospayarisi.py
72 lines (60 loc) · 1.19 KB
/
tospayarisi.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
import turtle
from random import *
from turtle import *
penup()
goto(-140,140)
for sp in range(15):
speed(10)
write(sp)
right(90)
forward(10)
pendown()
forward(150)
penup()
backward(160)
left(90)
forward(20)
tospa = Turtle()
tospa.color('green')
tospa.shape('turtle')
tospa.penup()
tospa.goto(-160,100)
tospa.pendown()
kaplumbağa = Turtle()
kaplumbağa.color('red')
kaplumbağa.shape('turtle')
kaplumbağa.penup()
kaplumbağa.goto(-160,80)
kaplumbağa.pendown()
karpuzcu = Turtle()
karpuzcu.color('blue')
karpuzcu.shape('turtle')
karpuzcu.penup()
karpuzcu.goto(-160,60)
karpuzcu.pendown()
bejo = Turtle()
bejo.color('black')
bejo.shape('turtle')
bejo.penup()
bejo.goto(-160,40)
bejo.pendown()
kavuncu = Turtle()
kavuncu.color('yellow')
kavuncu.shape('turtle')
kavuncu.penup()
kavuncu.goto(-160,20)
kavuncu.pendown()
lord = Turtle()
lord.color('aqua')
lord.shape('turtle')
lord.penup()
lord.goto(-160,0)
lord.pendown()
for turn in range(100):
tospa.forward(randint(1,5))
kaplumbağa.forward(randint(1,5))
karpuzcu.forward(randint(1,5))
bejo.forward(randint(1,5))
kavuncu.forward(randint(1,5))
lord.forward(randint(1,5))
turtle.done()