Python Turtle Graphics Project

Goal: Draw a complex picture using Python’s built-in Turtle Graphics module

Instructions:

  1. Create a new Python script & title it TurtlePicture.py
  2. Import the turtle module
    1. from turtle import *
  3. Create a pen
    1. pen = Pen()
  4. Acquaint yourself with the various Turtle methods
  5. Open a browser window with the Python documentation on Turtle Graphics
  6. Review the common methods below
  7. Draw a picture of a car, logo, animal, famous building, or self-portrait using turtle graphics

Common Turtle Methods:

  • forward() or fd()
  • backward() or bk() or back()
  • right() or rt()
  • left() or lt()
  • goto() or setpos() or setposition()
  • home()
  • circle()
    • For an arc, create a circle but add an extent between 1 and 359 for a partial circle
      • Ex. pen.circle(200, 180) would be a half-circle (180 degrees) with a radius of 200 pixels
  • stamp()
  • color() – Examples:
    • pen.color(‘red’) – using keywords
    • pen.color(‘#336699’) – using hexadecimal color codes
  • bgcolor() – to change the background color on the page
  • write(“Text Goes Here.”)

Scoring:

Scoring is based on the complexity of the shapes & designs as well as variety of colors. Must meet following (minimum) requirements for a passing grade:

  • Must use more than 2 colors
  • Must have a label or title on the picture
  • Must have at least 1 angle that isn’t a right angle
  • Must have a circle or arc as part of the picture
  • Must have evidence that the pen was lifted up and moved before being set down