Quiz #2


With a piece of paper, write down your name and answers to the following questions.

  1. The index to the last element of an array is:

    1. 100
    2. 0
    3. The length of the array
    4. One less than the length of the array
  2. This search algorithm repeatedly divides the portion of an array being searched in half:

    1. Binary Search
    2. Sequential Search
    3. Selection Search
    4. Iterative Search
  3. This type of method cannot access any non-static member variables in its own class.

    1. instance
    2. void
    3. static
    4. non-static
  4. What is the output of the following program.