Répondre :
Réponse :
Voilà normalement ça devrait être bon :)
from turtle import *
tur = Turtle()
tur.up()
tur.setposition(-350, 200)
def triangle():
tur.down()
tur.forward(230) # draw base
tur.left(120)
tur.forward(230)
tur.left(120)
tur.forward(230)
tur.up()
def carre():
tur.down()
tur.forward(230) #Forward turtle de 100 unités
tur.left(90) #rotation de turtle de 90 degrés
tur.forward(230)
tur.left(90)
tur.forward(230)
tur.left(90)
tur.forward(230)
tur.left(90)
tur.up()
def circle():
tur.down()
tur.circle(23*5)
tur.up()
def process1():
triangle()
tur.left(120)
tur.forward(270)
carre()
tur.left(0)
tur.forward(345)
circle()
tur.setposition(-350, -35)
def process2():
triangle()
tur.left(120)
tur.forward(385)
circle()
tur.left(0)
tur.forward(115)
carre()
tur.setposition(-350, -270)
def process3():
carre()
tur.left(0)
tur.forward(380)
circle()
tur.left(0)
tur.forward(115)
triangle()
tur.color('green')
process1()
tur.color('blue')
process2()
tur.color('red')
process3()
Merci d'avoir visité notre site Web dédié à Informatique. Nous espérons que les informations partagées vous ont été utiles. N'hésitez pas à nous contacter si vous avez des questions ou besoin d'assistance. À bientôt, et pensez à ajouter ce site à vos favoris !