1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 | import turtle t = turtle.Turtle() t.color('blue') t.width(10) t.penup() t.goto(-150,0) t.pendown() for n in range(3): t.forward(300) t.left(120) t.penup() t.goto(-150, 173) t.pendown() for n in range(3): t.forward(300) t.right(120) | cs |
height = (300**2 - 150**2)**0.5
y = height - height/3 # y = 173