Outline for October 17, 2012
Reading
: § 7
Assignment Due
: October 24, 2012 at 5:00PM
How to write a program
Problem statement: be explicit, specify exactly what the program needs to do
Goal
Specification
Design: state how the program will work in high-level terms
High-level design: what does the program actually
do
?
Data: how do you represent the data?
Functions: What functions do you need?
Refinement: refine until the design can be translated into code
Implementation: translate the statement into Python code
Example: Cæsar cipher
How it works
Encipher [
caesarenc.py
]
Decipher [
caesardec.py
]
A PDF version is available here.
ECS 10, Basic Concepts of Computing
Fall Quarter 2012