This website is preserved for historical and scholarly reference and is no longer actively maintained.

Reading Assignments and Reading Homework

CPSC 210 -- Spring 2001

The following reading assignments are made. Homework, in the form of a synopsis of the reading assignment, will be collected at the beginning of the designated class meeting. The intention of these assignments is (1) to persuade everyone to read the text books, (2) to allow the instructor to emphasize major concepts and critical points in the text material, and (3) to allow class discussions to introduce material not covered in the text.

Homework not turned in when collected in class will be designated "late." Late homework will be accepted until 4 p.m. on the date the homework is due. Homework will not be accepted after 4 p.m. on the date due except in exceptional circumstances. Homework will not be accepted by email. If class is cancelled due to inclement weather, the homework will be due at the next class meeting.

Homework must be typed (unless specified otherwise) using new Roman Times or Times 12 pt. font, single spaced, and double spaced between paragraphs. Unless specified otherwise, it is expected that the synopsis be at least 1.5 pages in length. Homework must have the name of the person submitting the homework typed at the top of the first page. All pages must be stapled together. Failure to follow instructions will result in deduction of points (1 pt. for no name, 1 pt. for not correctly stapled).

These homeworks will be valuable to you. You will be allowed to use your synopses on some daily quizzes, on hour quizzes, and on the final exam. Therefore, you should organize your work so that you can make the best use of it as a reference.

Homework is to be done individually. The purpose of the "read and report" homework is to make it possible to cover the course material effectively. Thus, it is important that each person read and write for themselves. If the instructor believes that homework has been jointly written, on the first occurrence the grade will be shared jointly among the writers. A second occurrence will be considered academic dishonesty and appropriate action will be taken.


#1 (due Friday, January 12)

Read Chapter 1 of Java Elements and write a synopsis of the material in this chapter. (8 pts.)

Include your solution to Problem 1.4 on pages 34-35 (2 pts.).

#2 (due Wednesday, January 17)

Note: Do not use the Console Window. Instead, use the ReadStream and PrintStream Classes, pages 334-335 of Java Structures. Do use the Drawing Window.

Read Chapter 2 of Java Elements and write a synopsis of Chapter 2. (8 pts.) Also, explain (one statement at a time, using a drawing at each step) how the code on page 57 draws the picture in figure 2.7. ( 2 pts.)


#3 (due Friday, January 19)

Read Chapter 3 of Java Elements and write a synopsis of Chapter 3 (8 pts.). Include the answer to Problem 3.13 on page 94 (2 pts.).


#4 (due Monday, January 22)

Read Chapter 4 of Java Elements and write a synopsis of Chapter 4. (8 pts.) Include the code for a method that tests to see if two rectangles (Rect) overlap (2 pts.).


#5 (due Wednesday, January 24)

Read Chapter 5 of Java Elements and write a synopsis for Chapter 5 (8 pts.). Include the answer to Problem 5.8 on page 143 (2 pts.).


#6 (due Friday, January 26)

Using indexOf, write a method contains that returns a boolean value indicating whether or not its parameter (a character) is contained within a String. (2 pts.) The method should be

public static boolean contains (String target, char symbol)
// post: returns true if target contains symbol
// otherwise, returns false.
{

#7 (due Monday, January 29)

Read Chapter 6 of Java Elements and write a synopsis for Chapter 6. (8 pts.) Write a recursive method to remove double letters from a word (represented as a String). (2 pts.) The method should be

public static String removeDouble (String word)
// post: All double letters have been removed from word
{


#8 (due Wednesday, January 31)

Write a recursive method to reverse the digits of an integer (int). The signature of the method should be:

public static int reverse ( int n )
// pre: n >= 0
// post: The digits of n have been reversed

For example, the reverse of 123 will be 321. ( 2 pts. )

#9 (due Friday, February 2)

Read Chapter 7 of Java Elements and write a synopsis for Chapter 7. Include an explanation of the action of each of the following Vector methods:

addElement ( Object itemm )
insertElementAt ( Object item, int index)
removeElementAt ( int index )
setElementAt ( Object item, int index )
removeElement ( Object item )

The Vector Class may be found on pages 303-304 of the Appendix. Use drawings to explain data movement when these methods are called. (8 pts.)

Work problem 7.8 on page 190. (2 pts.)


#10 (due Monday, February 5)

Read Chapter 8 of Java Elements and write a synopsis (7 pts.) for Chapter 8. Include the answer to exercise 8.2 (3 pts.) on page 234 (What is an "abstract data type," and why is it considered an improvement over systems that don't support data abstraction?).


#11 (due Wednesday, February 7

Explain how one class can extend another. ( 4 pts.) On page 222, explain the use of "this" and "super". (2 pts.) Explain the concept of interface. What is an interface? How is it used? (4 pts.)

Omit Chapter 9 of Java Elements except for definiton of container.


#12 (due Friday, February 9)

Read Chapters 10 and 11 of Java Elements and submit answers to the following questions: (10 pts.)

What is a container class?
What is the purpose of threads in Java?
What is a Java Virtual Machine and why is it important?
Why is the Turing machine an important concept?
What is a P-RAM? What is it used for?

No reading assignment for Monday, February 12 -- Hour Quiz 1



#13 (due Wednesday, February 14)

Read Chapters 0, 1, and 2 of Java Structures and answer the following questions (8 pts.):

What is an interface? How is it used?
Bailey creates a class named Association. Explain how one constructor calls the other.
Could another constructor be created for the BankAccount class with

Also, work Problems 2.2, 2.3, and 2.10. (0.5 pts. each for 2.2 and 2.3, 1 pt. for 2.10)

#14 (due Friday, February 16)

Read Chapter 3 (Vectors) of Java Structures and write a synopsis of Chapter 3. Work Problem 3.12 on page 48 (5 points for problem, 5 points for synopsis).

#15 (due Wednesday, February 21)

Read Chapter 4 (Design Fundamentals) of Java Structures and write a synopsis of Chapter 4. (8 pts.) Work Problem 4.2 on page 73 (2 points). You should clearly describe the situations which cause the best-case time and the worst-case time.

#16 (due Friday, February 23)

Work problem 4.3 on page 73 (2 pts.)

#17 (due Monday, February 26)

Read chapter 5 (Sorting) of Java Structures and write a synopsis of Chapter 5. Work Problem 5.6 on page 96. (problem 3 points, synopsis 7 points)

#18 (due Wednesday, February 28)

A sort is said to be stable if the order of equal values is maintained throughout the sort. Determine which of the following sorts are stable:

Bubble, Insertion, Selection, Merge, Quick

Give your reasoning for each. (1 pt. for each correct designation as stable or not stable. 1 pt. for presentation of justification -- for a total of 10 pts.)

#19 (due Friday, March 2)

Prepare and turn in a 1-page spreadsheet (10 pts.) containing the following information:
          Your name
          CPSC 210, Section 2
          A list of grades for daily quizzes (1-13), showing quiz number
               and date of quiz, the quiz average, and the quiz average
               if 3 grades are dropped before computing average.
          A list of reading grades (assignments 1-7, 9-12, and 16),
               listing the assignment number by each grade, and the
               average of these reading grades (your sum / maximum possible).
          Your grade on the first hour quiz, labelled.
          The grade you would receive if the final grade were based on these
               three components and their relative percentage allocation.
All information must be typed.

#20 (due Monday, March 12)

Read Chapter 7 (Linear Structures, including Stacks and Queues) of Java Structures. Write a synopsis of Chapter 7 (4 pts.) Work Problems 7.1 (1 pt.), 7.2 (1 pt.), 7.3 (2 pts.), and 7.4 (2 pts.) on page 152.

#21 (due Wednesday, March 14)

Work problem 7.5 ( 2 pts.), 7.6 (2 pts.) and 7.12 (6 pts.)

#22 (due Monday, April 16)

Read Chapter 9 (Ordered Structures) of Java Structures and write a synopsis of Chapter 9 (8 pts.). Answer questions 9.3 and 9.4 on on page 185 ( 1 pt. each). ************************************************************************
********* PAGE UNDER CONSTRUCTION FROM THIS POINT ON
************************************************************************

#16 (due Monday, October 30)

Read Chapter 8 (Iterators) of Java Structures and write a synopsis of Chapter 8. Work Problem 8.2 on page 165 (10 pts.). You will want to write an implementation of the iterator including instance variables, constructor, and the 4 methods listed on page 157. You do not need to compile and run your code, but your code is more likely to be correct if you do so. The synopsis is 10 pts. and Problem 8.2 is an additional 10 pts., making this reading assignment total 20 points (double assignment).

#17 (due Wednesday, November 8) .

Read Chapter 9 (Comparable Objects) of Java Structures and write a synopsis of Chapter 9.

#18 (due Monday, November 13)

Read Chapter 10 (Trees) of Java Structures and write a synopsis of Chapter 10.

#19 (due Monday, November 20)

Read pages 249-257 of Chapter 12 (Search Trees) and write a synopsis of these pages.


Return to Eleanor Hare's home page.

Return to Department of Computer Science Home page.