forked from extern/python-malbuch
32 lines
552 B
Plaintext
32 lines
552 B
Plaintext
## Code mit spazierender Schildkröte
|
|
|
|
from turtle import *
|
|
shape("turtle")
|
|
speed(100)
|
|
for i in range(12):
|
|
for i in range(8):
|
|
forward(100)
|
|
left(45)
|
|
right(30)
|
|
for i in range(8):
|
|
forward(50)
|
|
left(45)
|
|
done()
|
|
|
|
## Code für das Erstellen von einer svg Datei
|
|
|
|
from svg_turtle import SvgTurtle
|
|
t = SvgTurtle(1000, 1000)
|
|
|
|
for i in range(12):
|
|
for i in range(8):
|
|
t.forward(100)
|
|
t.left(45)
|
|
t.right(30)
|
|
for i in range(8):
|
|
t.forward(50)
|
|
t.left(45)
|
|
|
|
|
|
t.save_as('PyTurtle1.svg')
|