CPSC120
Fundamentals of Computer Science

In-class Activity 6

  1. Draw Rectangle

    Create a Python function that takes a width, and a height and draws a rectangle of the specified dimensions.

  2. Draw Rectangle At

    Create a Python function that takes an x coordinate, a y coordinate, a width, and a height and draws a rectangle of the specified dimensions that is centered on the specified position. To move the turtle without drawing, use the penup and pendown functions. To move the turtle to a specific location, use the goto function.