



|
|
CS1 Course Site
|
Class Notes
Monday November 27 , 2000
|
|
Announcements
EXAM 3
Monday December 4, 2000
- not practice exam
- topics will include:
- superficial signatures
- parameter passing and value returning
- searching and sorting
- other things (objects, control constructs, strings, arrays)
FINAL EXAM
Monday December 11, 2000
7 pm - 9 pm Room 102 Snygg
- Half will be devoted to questions having to do with the words package, ``extensions'' of the package, and applications which make use of the packages.
- Half will be based on other things we have addressed throughout the semester.
- On the 6 th I will give you a ``practice'' final.
MORE THINGS
- For ``competition'' purposes, your web site should be together soon, in time to have your lab instructor consider it for advancement.
- For ``grading'' purposes, your site must be complete by 7 pm on Monday December 11 th.
- The fairly modest 2 nd part of your assignment will be distributed on the 29 th. It will be due at the final.
- Part 1 of your assignment is due December 6 th.
Definition
The SUPERFICIAL SIGNATURE of a Java program fragment is the fragment with:
- All literals (constants) replaced by their type in angular brackets.
- All objects referenced by variables replaced by the type of the object in angular brackets.
Example
int x = 5;
double y = 3.5;
double p = x * y;
IO.println (``The product is ``+ p);
|
The superficial signature is....
int x = < int >;
double y = < double >;
double p = < int > * < double >;
IO.println (< String > + < double >);
|
Example
Circle c = new Circle (10);
Square s = new Square (10.0);
double aa = (c.area () + s.area ()) / 2.0;
|
The superficial signature is....
Circle c = new Circle (< int >);
Square s = new Square (< double >);
double aa = (< Circle > .area () +
< Square > .area ()) / < double >;
|
|
|