Turtle graphics

In this program we learn how use turtle program and use it randomly for its movement. Following is the source from python.

import turtle
import random

Window = turtle.bgcolor(“red”)

Mehedi = turtle.Turtle()

Mehedi.color(“white”)

Mehedi.shape(“turtle”)

for x in range(100):

rand=random.randint(0,45)

randd=random.randint(0,150)

Mehedi.right(rand)

Mehedi.forward(randd)

Mehedi.backward(randd)