GoConqr hat ein neues Design! Sag uns, wie es dir gefällt.

Quiz

chapter 11 quiz

Joe Delisle 106 Fragen

Quiz starten

Fragen in diesem Quiz (106)

  1. 1Suppose an ArrayList list contains {"red", "green", "red", "green"}. What is the list after the following code?Bild zu Frage 1
    1. A{"red", "green", "red", "green"}
    2. B{"green", "red", "green"}
    3. C{"green", "green"}
    4. D{"red", "green", "green"}
  2. 2Which of the following statements is false?
    1. AA public class can be accessed by a class from a different package.
    2. BA private method cannot be accessed by a class in a different package.
    3. CA protected method can be accessed by a subclass in a different package.
    4. DA method with no visibility modifier can be accessed by a class in a different package.
  3. 3Invoking ________ removes all elements in an ArrayList x.
    1. Ax.remove()
    2. Bx.clean()
    3. Cx.delete()
    4. Dx.empty()
    5. Ex.clear()
  4. 4What is the output of the following code?Bild zu Frage 4
    1. Afalse false
    2. Btrue true
    3. Cfalse true
    4. Dtrue false
  5. 5The UML uses ________ before a member name to indicate that the member is private.
    1. A+
    2. B-
    3. C#
    4. D?
  6. 6Analyze the following code.Bild zu Frage 6
    1. AProgram 1 displays true and Program 2 displays true
    2. BProgram 1 displays false and Program 2 displays true
    3. CProgram 1 displays true and Program 2 displays false
    4. DProgram 1 displays false and Program 2 displays false
  7. 7You can create an ArrayList using ________.
    1. Anew ArrayList[]
    2. Bnew ArrayList[100]
    3. Cnew ArrayList()
    4. DArrayList()
  8. 8You can use the operator == to check whether two variables refer to the same object, and use the equals() method to check the equality of contents of the two objects.
    1. ARichtig
    2. BFalsch
  9. 9The printout from the following code is ________.

    java.util.ArrayList<String> list = new java.util.ArrayList<String>();
    list.add("New York");
    java.util.ArrayList<String> list1 = list;
    list.add("Atlanta");
    list1.add("Dallas");
    System.out.println(list1);
    1. A[New York]
    2. B[New York, Atlanta, Dallas]
    3. C[New York, Dallas]
    4. D[New York, Atlanta]
  10. 10________ can search in an unsorted list.
    1. ALinear search
    2. BBinary search

Informationen

Beschreibung
Quiz am chapter 11 quiz, erstellt von Joe Delisle am 10/02/2018.
Sprache
English
Aufrufe
2
Bewertung
Noch keine Bewertungen
Bewerte dieses Quiz
Bewerte dieses Quiz

Feedback

Worum geht es?

Wie gefällt dir das neue Design?

Dein Eindruck