CSE131 Lecture Highlights

Copyright © 1996-2006, Kenneth J. Goldman
 
These CSE131 Lecture Highlights are provided to help you review material covered in class, and to free you from constantly copying from the board so that you can pay attention, think about what's going on, and ask questions.

Do not use these notes as a substitute for attending class. The notes that follow are covering material from previous semesters, not necessarily exactly what we're doing this semester.  If you read these notes without attending class, they may not make sense to you, it will take you longer to understand the material, and you won't learn as much. (Don't be fooled by the high level of detail in the notes for the first few lectures. These are meant to accommodate students who add the course late. The notes for later lectures will often have much less detail.)

The easiest way to learn the material well is to attend class and do the lab assignments carefully, reviewing these notes as needed, in much the same way that you would use your own notes.

Acknowlegement: A special thanks is owed to Daniel Schepler, who carefully transcribed much of this material from my handwritten lecture notes. -- kjg

Additional material from this semester's lectures will be posted, as they become available, on the resources pages associated with each of the course modules.

Introduction

Process and Procedure
Abstraction
Decomposition
Software Systems
Syntax and Semantics
Elements of Programming Languages
Java and Object-Oriented Programming

Data Types and Expressions

Precedence Rules
Expression Trees
Substitution Model
String Expressions
Boolean Expressions

Variables and Naming Abstraction

Variables
Using Variables in Expressions

Procedural Abstraction

Example: areaOfCircle
Example: hypotenuse
Built-in Mathematical Procedures
A Complete Program
Advantages of Procedural Abstraction
Reduction
Example: rect_diag

Conditional statements
Using the return values from procedures as tests
Good and bad style in writing conditional statements

Instructions and Memory: A peek inside the machine

Compilation and Execution

The Execution Stack and Activation Records
Call-by-Value

Compound Data

Example: Couple
Objects as Containers
Methods that Update Instance Variables
Example: Account
Objects that Invoke Methods on Other Objects
Example: Temperature
Calling Methods from Within an Object
Example: Sphere Object

Documentation, Testing, and Debugging

Forms of Documentation
Principles of Testing
Taxonomy of Program Errors
Compilation Errors
Run-time Errors
Correcting Compiler Errors
Correcting Run-Time Errors (Debugging) Using a Debugger

Data Abstraction

Example: CS101Canvas
Example: Baseball Scorekeeper
Example: Rational Number ADT

Recursion and Recursive Algorithms

Example: factorial
Example: add
Example: Primality Tester
Example: Fibonacci Numbers
Example: GCD
GCD Algorithm 1: Brute Force
GCD Algorithm 2: Euclid's Algorithm
GCD Algorithm 3: Dijkstra's Algorithm
Example: Square Root
Newton-Raphson Root Finding Algorithm
Finding the New Guess
Determining When We're Close Enough
Putting it All Together

Iteration and Iterative Algorithms

Exponentation
Fibonacci
Iteration in Graphics

Introduction to Data Structures

Recursion over Linked Lists
Iteration over Linked Lists
A List of Numbers ADT
Horner's Method
Data Structures in other ADTs
Example ADT: Relation
Stacks
Queues
Circular Lists
 

Multiple representations

Example: BaseNumber
Example: Set
Representation A: Linked List
Representation B: Ordered List
Representation C: Sets as Trees

Arrays

Introduction to Software Design

The Stable Marriage Problem
Class Hierarchies
Technical Issues Surrounding the Class Hierarchy Concept
Polymorphism
Examples of Object-Oriented Design

Applets


Kenneth J. Goldman