Python Turtle - Colourful Spirograph Tutorial

Pubblicato il: 06 aprile 2020
sul canale di: Geek Tutorials
7,944
102

Learn how to quickly and easily draw a colourful hexagonal spirograph using the Turtle module in Python.

⭐ 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)
bgcolor("black")

colours = ["red", "purple", "blue", "green", "orange", "yellow"]

for i in range(360):
pencolor(colours[i%6])
width(i / 250 + 1)
forward(i)
left(59)

hideturtle()


In questa pagina del sito puoi guardare il video online Python Turtle - Colourful Spirograph Tutorial della durata di ore minuti seconda in buona qualità , che l'utente ha caricato Geek Tutorials 06 aprile 2020, condividi il link con amici e conoscenti, su youtube questo video è già stato visto 7,944 volte e gli è piaciuto 102 spettatori. Buona visione!