Loop In Turtle
# SQUARE
python2.7
import turtle
t = turtle.Pen()
for i in range(0,4):
t.forward(50)
t.left(90)
# 8 SQUARE
python2.7
import turtle
t = turtle.Pen()
for i in range(0,8):
t.forward(50)
t.left(45)
# STAR
python2.7
import turtle
t = turtle.Pen()
for i in range(0,5):
t.forward(100)
t.right(144)
# S.TH
python2.7
import turtle
t = turtle.Pen()
for i in range(1,76):
t.forward(222)
t.left(175)
# S.TH
python2.7
import turtle
t = turtle.Pen()
for i in range(1,144):
t.forward(333)
t.left(175)
# S.TH
python2.7
import turtle
t = turtle.Pen()
for i in range(0,30):
t.forward(333)
t.right(156)
No comments:
Post a Comment