N
Size: a a a
N
IK
ИБ
Тᅠ
VA
АН
a
YS
a
a
a
t.forward, t.right, t.right, t.forward, t.forward
t.forward, t.left, t.forward, t.left, t.forward, t.right, t.right,t.right, t.forward, t.forward
t.left, t.forward, t.right, t.right, t.forward, t.left, t.forward
t.right, t.forward, t.forward, t.left, t.forward, t.left, t.forward,t.forward, t.left, t.forward
-------------------------------------
import turtle as t
def turtle_one():
t.penup()
t.forward(30)
t.pendown()
t.left(90+30)
def transition():
if i == zero:
t.penup()
t.left(180)
t.forward(100)
t.pendown()
t.left(270)
else:
t.left(180)
t.penup()
t.forward(120)
t.right(90)
t.forward(20)
if i == seven:
t.forward(40)
t.left(270)
t.pendown()
t.shape('turtle')
t.speed(4)
t.width(3)
t.color('blue')
x_constanta = 60
t.penup()
t.goto(-200, 0)
t.left(-90)
t.pendown()
line_number = 0
with open('turtle_list.txt', 'r') as file:
for line in file:
list_number = line.split(',')
line_number += 1
counter = 0
x_constanta = 60
if list_number == 1 :
turtle_one()
for k in list_number:
print(type(k))
if list_number == 2 and k == t.left or list_number == 3 and k == t.left:
t.left(x_constanta / 2)
if list_number == 3 and k == t.left and counter == 5 or\
list_number == 4 and k == t.right and counter == 0:
k(-60)
if list_number == 4 and k == t.left and counter == 3 or list_number == 4 and k == t.left:
k(30)
k(x_constanta)
counter += 1
transition()
YS
YS
YS
YS
a
NP
E