Successfully reported this slideshow.
We use your LinkedIn profile and activity data to personalize ads and to show you more relevant ads. You can change your ad preferences anytime.
Using a Turtle
Imagine a Turtle …
 Crawling over a huge
sheet of paper
 With a pen tied to its
tail.




You can comma...
The basics

Tells Python to use the
Turtle module

Sets up a Turtle and makes
it a Turtle Shape

Moves forward 100 pixels
...
Challenges


Draw a square:
 By repeating the same commands four times


 Using ‘For I in range(4):’ 



Draw a hex...
Turtle graphics
Upcoming SlideShare
Loading in …5
×

Turtle graphics

1,615 views

Published on

  • Be the first to comment

  • Be the first to like this

Turtle graphics

  1. 1. Using a Turtle Imagine a Turtle …  Crawling over a huge sheet of paper  With a pen tied to its tail.   You can command it.
  2. 2. The basics Tells Python to use the Turtle module Sets up a Turtle and makes it a Turtle Shape Moves forward 100 pixels Turns right by 90 degrees Closes the graphic window when you quit
  3. 3. Challenges  Draw a square:  By repeating the same commands four times   Using ‘For I in range(4):’    Draw a hexagon Allow the user to say how many sides the polygon should have  Remember, use ‘myVariable = int(raw_input)’ to get a number from the user  Get the turtle to draw your initials

×