CIT 591 Third Quiz
Fall 2001, Dave Matuszek
Name __________________________________________
  1. What kind of Layout is described by each of the following?
    You can put up to five components in it:
    You specify how many rows and columns it has:
    You add components to the NORTH, EAST, etc.:
    Components are made as small as possible:
    Arrangement of components depends on size of the container:

  2. Name two kinds of Component (capitalization must be correct).

  3. When you say that a class implements an interface, what are you promising that the class will do?

  4. If you declare a method without defining it (that is, without providing a method body), it is an ____________________ method.

  5. What, briefly, is Style Rule 1?

  6. In RabbitHunt, what value is returned by the method call Model.turn(Model.N, 4) ?

  7. If ch is a char, the following statement is syntactically incorrect because the expression on the right yields an int, not a char. Fix the statement. Do not put in additional statements that I did not ask for.
              ch = ch + 1;

  8. What value is computed by each of the following expressions?
    37 % 2 n + 5 > n
    (int) 12.98 2 + 2 == 4 ? 'a' : 'b'
    10 << 2 w = 3

  9. What method is used by System.out.println to get the string representation of objects?

  10. You overload a method by writing another method with the same name; what must be different about the new method?