Skip to content
A series of python exercises to explore constructing 2D images, iteratively and recursively.
Python
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
Gui.py
README.md
TurtleWorld.py
World.py
turtle_draw.py

README.md

drawing_with_turtles

A series of python exercises to explore constructing 2D images, iteratively and recursively. Completed in a CS class with Professor Jim Fix at Reed College, 2014.

In this assignment, I write the file turtle_draw to work through a series of drawing challenges using a Turtle object that constructs a Turtle Pen on a canvas. An instantiated Turtle can change direction (angles measured in degrees), shift its pen to be on or off the canvas, and move forward a given number of units.

Exercies 1 through 8 each present functions that draw specific images when given various parameters:

Ex. 1: A hexagon of variable length.

Ex. 2: A grid of variable shapes in variable positions.

Ex. 3: A polygon maker -- give this function n number of sides, and it returns a function that creates a polygon of n sides

Ex. 4: A star maker -- give this function n numer of sides, and it returns a function that draws a star of n sides

Ex. 5: A circle of variable radius.

Ex. 6: An arc of a given length carved from a circle of a given radius.

Ex. 7: A flower with n number of petals.

Ex. 8: A Koch snowflake, constructed recursively. Read more about the Koch snowflake here:

http://en.wikipedia.org/wiki/Koch_snowflake

To test, un-comment out whatever line of the test cases you want to try out in terminal.

You can’t perform that action at this time.