repl.it
@AHulot/

Drawing_4_Repl

Python (with Turtle)

No description

fork
loading
main.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
import turtle

turtle.color("red")
sides = 0

while sides < 8:
  turtle.right(45)
  turtle.forward(100)
  sides = sides + 1

turtle.up()
turtle.forward(120)
turtle.down()
turtle.color("blue")
turtle.right(45)
turtle.forward(100)
turtle.right(135)
turtle.forward(100)
turtle.right(110)
turtle.forward(80)

turtle.up()
turtle.forward(100)
turtle.down()
sides = 0

while sides < 4:
  turtle.color("green")
  turtle.forward(100)
  turtle.right(90)
  sides = sides + 1
result
console