1def turtle_triangle():
2 window = turtle.Screen()
3 window.bgcolor("red")
4
5 brad = turtle.Turtle()
6
7 brad.shape("turtle")
8 brad.color("yellow")
9 brad.speed(1)
10
11 for _ in range(3):
12 brad.right(60)
13 brad.forward(200)
14 brad.right(60)
15
16 window.exitonclick()
1>>> player_one = turtle.Turtle()
2>>> player_one.color("green")
3>>> player_one.shape("turtle")
4>>> player_one.penup()
5>>> player_one.goto(-200,100)
6>>> player_two = player_one.clone()
7>>> player_two.color("blue")
8>>> player_two.penup()
9>>> player_two.goto(-200,-100)
10
1import turtle
2import random
3
4window = turtle.Screen()
5
6tortuga = turtle.Turtle()
7
8tortuga.speed(1)
9
10
11window.exitonclick()