Python Turtle - Code the Lithuanian Flag Tutorial

Publié le: 22 avril 2020
sur la chaîne: Geek Tutorials
711
12

Learn how to quickly draw the Lithuanian flag using Python's Turtle module.

⭐ Kite is a free AI-powered coding assistant that will help you code faster and smarter. The Kite plugin integrates with all the top editors and IDEs to give you smart completions and documentation while you’re typing. I've been using Kite for 6 months and I love it! https://www.kite.com/get-kite/?utm_me...

~ CODE ~

from turtle import *

speed(0)
setup(800, 500)

Move to start position
penup()
goto(-400, 250)
pendown()

Yellow
color("gold")
begin_fill()
forward(800)
right(90)
forward(167)
right(90)
forward(800)
end_fill()

left(90)

Green
color("darkgreen")
begin_fill()
forward(167)
left(90)
forward(800)
left(90)
forward(167)
end_fill()

left(180)
forward(167)

Red
color("firebrick")
begin_fill()
forward(167)
right(90)
forward(800)
right(90)
forward(167)
end_fill()

hideturtle()


Sur cette page du site, vous pouvez voir la vidéo en ligne Python Turtle - Code the Lithuanian Flag Tutorial durée heure minute seconde en bonne qualité , qui a été Téléchargé par l'utilisateur Geek Tutorials 22 avril 2020, Partagez le lien avec vos amis et connaissances, sur youtube cette vidéo a déjà été regardée 711 fois et il a aimé 12 téléspectateurs. Bon visionnage!