Getting Started

Getting Started: Python and IDLE (PDF)

If you are working on your own machine, you will probably need to install Python. We will be using the standard Python software, available here. You should download and install version 2.5.4.

TECHNICAL NOTE: Some modern operating systems, particularly OS X El Capitan, no longer allow Python 2.5.4 to be installed. If that’s the case, you may instead install Anaconda, which includes standard Python as well as numpy, pylab, and many other extensions. Please install Anaconda for Python 2.7.

WARNING: On the Python homepage, the latest version available for download is actually 3.5. Do not install this! This version is not backwards compatible with the code that you’ll be writing in this course (for example, you have to type print(“test”) instead of print test.)

0 A very simple program: entering and printing your name (PDF)  
1 Computing prime numbers, product of primes (PDF)  
2 Diophantine equations (PDF) (PY)
3 Matching strings: a biological perspective (PDF) (PY)
4 Simulating a retirement fund (PDF) (PY)
5 Word games (PDF) (PY) (PY) (PY)

words.txt (TXT)

6 Word games 2 (PDF) (PY)

words.txt (TXT)

7 Review problems (PDF)  
8 Dynamic programming (PDF) (PY)

subjects.txt (TXT)

9 Classes and methods (PDF) (PY)

shapes.txt (TXT)

10 Object-oriented programming; graphical user interface for word game (PDF) (PY) (PY) (PY)

words.txt (TXT)

11 Simulating robots (PDF) (PY) (PY)

12 Simulating virus population dynamics (PDF) (PY)

Course Info

Learning Resource Types

assignment Problem Sets
theaters Lecture Videos
grading Exams with Solutions