CS 2213/2211
Advanced Programming Quiz 2, Spring 2005
Date and time: Quiz 2 will be given in the lecture class on:
2005-02-10, that is, Thursday, 10 February 2005, 9:30 am - 10:45 am, at the beginning or the end of class.
Topics:
Sep. Compilation:
Understand the use of separately compiled files in C with header files.
Sieve:
Study the comparison and contrast between the C program in 3 files and the Java program
in 2 files:
The C program has a header file included in each of the two other source
files to insure compatibility and to allow separate compilation. Java doesn't
use these header files (except in interfaces), and one can't compile
the file with the main function without compiling the other one.
Each Java file has code buried within a class, and C has nothing like this.
A number of other differences outlines in the web page.
Stack:
This is a 3-way comparison, but questions will be about the C version of a stack.
O-O Prog:
Pay special attention to the table that shows how C uses separate files
to enable O-O programming.
Copy:
These character-by-character copy programs are needed for Recitation 3,
but it is important to see how C uses
getchar() and a test for
EOF to copy a file.
To copy line-by-line, just realize that in C files appear as if
lines are separated from one another by a single newline character.