PL: Java Questions: 1. Which of the following statements is correct? (Select all
ID: 3578843 • Letter: P
Question
PL: Java
Questions:
1. Which of the following statements is correct? (Select all that apply)
a. Comparable c = new Date();
b. Comparable c = "abc";
c. Comparable c = new Date();
d. Comparable c = new String("abc");
link: https://scontent.xx.fbcdn.net/v/t1.0-9/15317999_1252601948138897_1787014966259879157_n.jpg?oh=e89cc98fd225155bec47ea0063ded0a4&oe=58B523CF
2. Which of the following statements are true? (Select all that apply)
a. java.util.PriorityQueue implements the java.util.Queue interface.
b. java.util.LinkedList implements the java.util.Queue interface.
c. java.util.ArrayList implements the java.util.Queue interface.
d. java.util.LinkedHashSet implements the java.util.Queue interface.
e. java.util.HashSet implements the java.util.Queue interface.
Link: https://scontent.xx.fbcdn.net/v/t1.0-9/15420811_1252601954805563_6384119270810133855_n.jpg?oh=bce70e53fb0db8c7a4da3f52064fe47c&oe=58B5D4F3
3. Which of the following statements are true?
a. All the methods in HashSet are inherited from the Collection interface.
b. All the methods in LinkedHashSet are inherited from the Collection interface.
c. All the concrete classes of Collection have at least two constructors. One is the no-arg constructor that constructs an empty collection. The other constructs instances from a collection.
d. All the methods in TreeSet are inherited from the Collection interface.
e. All the methods in Set are inherited from the Collection interface.
Link: https://scontent.xx.fbcdn.net/v/t1.0-9/15542045_1252601951472230_5464442208435923755_n.jpg?oh=55a67b6b6809582f8fc7f35b4c48319c&oe=58F92249
Partial Question 43 Which of the following statements is correct? Comparable c new Date0: Comparable c abc Comparable c new Date Comparable c new String( "abc"); 1/2 ptsExplanation / Answer
Answer: Options
43. d. Comparable c = new String("abc");
46.a. java.util.PriorityQueue implements the java.util.Queue interface.
b. java.util.LinkedList implements the java.util.Queue interface.
c. java.util.ArrayList implements the java.util.Queue interface.
e. java.util.HashSet implements the java.util.Queue interface.
47. a. All the methods in HashSet are inherited from the Collection interface.
c. All the concrete classes of Collection have at least two constructors. One is the no-arg constructor that constructs an empty collection. The other constructs instances from a collection.
d. All the methods in TreeSet are inherited from the Collection interface.
Related Questions
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.