CS 115 Lab 3, Spring 2015
Deadlines
- Pre-lab: Tu 2/3/2015 at 7 AM
- Writeup and code (lab03e.py): Tu 2/10/2015 at 4 PM
- Demo (parts A and E): Any lab section, workshop, or open tutoring session before Tu 2/10 at 4 PM. Your last chance is the Tuesday tutoring from 3-4 PM.
Goals
Upon successful completion of this lab, you should be able to write and edit Python programs
that use:
- definite loops
- ranges
- the accumulator pattern
Pre-Lab Assignment
Click here for the pre-lab instructions.
Even if you didn't get to the pre-lab by the deadline, you should work through it before proceeding with the rest of the lab.
Setup
- Before you start writing code, you will set up a directory for this assignment
on the cwolf server. To connect to cwolf, do one of the following:
- Enter your CS 115 subdirectory by typing
cd cs115
- Type pwd (print working directory) and verify that the output is:
/home/student/yourusername/cs115
- Create a directory for Lab 3 by typing
mkdir lab03
- Enter your Lab 3 directory by typing
cd lab03
- Type pwd again, and verify that the output is:
/home/student/yourusername/cs115/lab03
- For now, close Terminal or PuTTY. You will do most of this lab in IDLE.
Lab Instructions
Follow the links below to complete each part of this lab.
- Sum a list of numbers
- Draw arbitrary circles
- Draw a stack of circles
- Draw a stack of circles using a for-loop
- Draw a square of circles
- Submit the assignment