Skip to main content

Featured

Awesome Python Turtle

Awesome Pythhon Turtle Colour Changing Vibrant Circle in Python import turtle tur=turtle.Turtle() scr=turtle.Screen() scr.bgcolor('black') tur.pencolor('white') x=0 y=0 tur.speed(0) tur.penup() tur.pendown() colors = ['red', 'purple', 'blue', 'green', 'orange', 'yellow'] while True: tur.pencolor(colors[y%6]) tur.forward(x) tur.right(y) x +=3 y +=1 if y==210: break tur.hideturtle() turtle.done() Output:

Python Turtle Programs

 

Vibrant Circle Python Turtle

import turtle

tur=turtle.Turtle()

scr=turtle.Screen()

scr.bgcolor('black')

tur.pencolor('white')

x=0

y=0


tur.speed(0)

tur.penup()

tur.goto(0,200)

tur.pendown()


while True:

tur.forward(x)

tur.right(y)

x +=3

y +=1

turtle.done()


Output:



Comments

Popular Posts