|
Second Summer 2002 |
| Calendar and Exams | Office Hours | Grading | Course Materials | QuizSite | MyGrades |
| [01] June 17 [02] June 18 [01] Lab 1 (6/17) |
[03] June 19 [04] June 20 [02] Lab 2 (6/20) Homework One |
[05] June 24 [06] June 25 [03] Lab 3 (6/24) |
[07] June 26 [08] June 27 [04] Lab 4 (6/27) Homework Two |
| [09] July 1 [10] July 2 [05] Lab 5 (7/1) |
[11] July 3 [11] HOLIDAY [06] No Lab Homework Three |
[12] July 8 [13] July 9 [06] Lab 6 (7/8) |
[14] July 10 [15] July 11 [07] Lab 7 (7/11) MIDTERM Fri 7/12 |
| [16] July 15 [17] July 16 [08] PRACT 7/15 Homework Four |
[18] July 17 [19] July 18 [08] Lab 8 (7/18) |
[20] July 22 [21] July 23 [09] Lab 9 (7/22) Homework Five |
[22] July 24 [23] July 25 [10] Lab 10 (7/25) |
| [24] July 29 [25] July 30 [11] Lab 11 (7/29) Homework Six |
[26] July 31 [27] August 1 [12] Lab 12 (8/1) |
[28] August 5 [29] August 6 [13] Lab 13 (8/5) |
[30] August 7 [31] August 8 [14] Lab 14 (8/8) FINAL Fri (8/9) |
Where all the notes will be collected, in
a format more suitable for ClassPak delivery.
Syllabus (Calendar and Exams)
Here's a brief syllabus for A201/A597/I210 this semester:
Here now is a somewhat more detailed perspective on it:
What computers can do and how. Programming languages. Java. Syntax. Writing
simple programs for a robot-like penguin in rectangular world. Objects in Java
and the syntax of method invocation. The edit-compile-run loop. Syntax of the
simplest running program in Java, and the structure of
More examples of algorithms: a simple investment problem; positional
algorithms for addition and multiplication of integers; calculating the
greatest common divisor by Euclid's method; sorting a list of numbers.
Simple programs that print strings. Syntax of strings. Simple expressions
with numeric value. Number types. Integer vs. floating-point numbers. Some
issues of precision and internal representation. Symbolic names. Variables.
Declaration and initialization of (local) variables.
Assignment statements. Operators, operands, precedence tables, left to
right associativity, order of evaluation. Type conversion: casting a float
value for assignment into an integer variable. Method invocation revisited.
Basic I/O in Java. Using
Basic modeling: designing a simple
More about methods: return types. Parameters, arguments. Constructors as
initialization procedures. Instance variables vs. local variables. Basic
terminology in the context of this example: mutators vs. accessors.
The
The
The
Relational operators. Comparing floating point numbers. The difference
between reference and primitive types when comparing for equality.
Indentation and style in writing programs.
Basic
Case studies: generating random numbers, and using them in Monte Carlo
experiments. Experimentally determining the value of pi. Frequencies and
probabilities. Traversing the characters in a
Classes and objects revisited: a diagrammatic review. Instance vs. static
members. Variable initialization, lifetime and scope: parameters vs. local
variables vs. instance variables vs. static variables. Side-effects.
Recursion.
Overloading.
Case study: writing a
Basic description of the class extension mechanism through the set
union of features example. Making the robot-like penguin in Iceblox
smarter through class extension.
Overriding of methods. The rule of dynamic method lookup.
One-dimensional arrays of integers. Searching, counting, inserting,
deleting, finding the maximum and the minimum values in an array of
integers. Array parameters and return values.
Parallel arrays. Arrays of objects.
Two-dimensional arrays.
Sorting: selection sort and bubble sort. Recursive methods of sorting.
Applets are described in the context set up at step 7 (above). The structure
and life cycle of an applet. How
Simple user input in an applet: listeners for the mouse and the keys.
Interfaces. Events, event listeners, and event sources. Adapter classes.
Implementing listeners as inner classes.
Windows and frames. Layout management. Basic AWT components.
Case study: exploring the Swing documentation (the
Definition of threads. The
The four kinds of threads programming problems:
We take a look at double-buffering and implement an
The program is developed step by step. It's meant to offer a clear
perspective on what A202 might look like, also what it takes to create
an enjoyable piece of software. (After Joel Fan.)
Karl Hornell's 1996 original Iceblox program is used. The style of
the program is completely procedural. Thus we have a very robust but
extremely hard to understand computer game program. We are then presented with
an alternative design that follows Hornell's organization exactly, but
encodes everything using a hierarchy of classes starting with a
Two written exams,
There are multiple-choice exercises posted for practice in QuizSite.
The AI uses the first 15-20 minutes to go through the entire class
and individually takes attendance, greets students to the lab, and
asks each student to identify one or two most outstanding questions
(s)he might have about the current or forthcoming lab and homework
assignment. Thus the AI builds a set of FAQ for the lab, each lab,
and soon learns the names of all students in the lab.
The AI combines the answers into a 20-30 min presentation which may
involve student participation. The presentation is blending the topic
for the day (predetermined) with the answers to the FAQ collected by
the ad-hoc survey.
Last 60-70 minutes of the lab the AI again goes through the entire
set of students and checks that the lab assignment has been completed.
Student runs the lab program and answers one or two questions.
Grading scale for the lab:
Labs are meant to stimulate participation and encourage learning.
Exams and (to a significant extent) homework assignments are the main
testing instruments used in the class.
Office Hours are listed in the table below:
Grading Scale (as mentioned above)
Course grades will be determined as follows:
main. Math methods that return values: Math.sqrt(),
Math.round(), Math.floor(), Math.ceil(),
Math.pow(), Math.abs(), Math.max(), etc.
Other integer types. Infinite-precision arithmetic with big number objects. ConsoleReader (a helper class) to write
simple interactive programs. Objects revisited: using java.awt.Rectangle
in a few programs. Basic introduction to the standard Java API and packages. Primitive
types vs. reference types. BankAccount class with one instance
variable (the balance) and three instance methods (getBalance,
withdraw, and deposit). Basic introduction to methods: their
names and signatures. null reference. this keyword for self-reference. The use of this() in constructors. boolean primitive type. Simple boolean algebra. De Morgan's laws.
Syntax of an if statement. Nested branches, the dangling else problem. while loops in the context of the investment problem from the
beginning. Infinite loops. Syntax of the for and do-while loops. Equivalence
between while and for loops. "Off by one" errors, the loop and a half
problem.
More syntax: break and
continue. Nested loops and two-dimensional patterns.
Loop invariants, correctness proofs (Euclid's algorithm). String using
charAt(). The
primitive type
char and its relationship to integers. Using StringTokenizer
to simulate a stack of String values in an interactive program. Strings
and stacks as linear structures that anticipate our study of Java arrays. Fraction class. Vectors. Casting. Hashtables. paint() works: the rule for dynamic
method lookup in action. Applets vs. applications. Basic HTML and the
appletviewer application. The graphics context object and its methods.
Graphical shapes, fonts, colors, and the ManyShapes applet. SliderTest program). Runnable interface. a) unrelated threads,
This presentation is valuable because it's meant to offer a glimpse of
A202 programming, and also a short and complete course
on generic threads programming (after van der Linden).
b) related (but unsychronized) threads,
c) mutually-exclusive threads, and
d) communicating and mutually-exclusive threads. x-eyes applet. World
and an Actor class. Given that Hornell's original program is a paragon
of procedural programming, the object-oriented version that we develop
offers a clear understanding of the advantages that object-oriented
design provides from a purely conceptual point of view.
One practical exam,
Each of the 14 labs comes with
There are six homework assignments on
Minute papers collected every lecture count towards final grade. Vectors and Hashtables).
45 points for showing up
Note: 95 is the highest A, 90 is the lowest. Points above 95 are only
given for student work that is of such quality that it makes the AI want
to share it with the entire class. Grade cutoffs are posted on the website, below.
up to 10 points for initial interaction (for the FAQ)
(4, 3, 2, or 1) x 10 points if the program is worth an A, B, C, or D.
Instructor Username Days Location Time Adrian German dgerman MTWF LH201D
3-4pm
Thursday(only) LH201D 12:25-1:25pm
Richard Li yli TW LH016
(basement, Lindley) 5:30-6:30pm
Barry Li yinli MR LH016
(basement, Lindley) 2:30-3:30pm
| Component | Weight |
|---|---|
| 6 Homework Assignments | 25% |
| 14 Lab Assignments | 35% |
| Midterm Exam | 15% |
| Practical Exam | 15% |
| Final Exam | 15% |
| Lecture Minute Papers | 5% |
TOTAL | 110% |
The overall cutoff scale is as follows:
| 0-54 | 55-65 | 66-67 | 68-69 | 70-75 | 76-77 | 78-79 | 80-85 | 86-87 | 88-89 | 90-95 | 96-100 |
| F | D | D+ | C- | C | C+ | B- | B | B+ | A- | A | A+ |
The textbook is pictured on the right.
Here's what you will need, in essence:
Course Materials
If you want to work from home you will need to install your own compiler.
We might be able to assist you with that, but we make no promise. Lecture
notes and lab notes will be posted regularly together with reading assignments.
We will be checking out the on-line
API
(from Sun) frequently. Here's a no frames, and complete