Exam 16: Collections,maps,and Iterators
Exam 1: Getting Started45 Questions
Exam 2: Console Input and Output29 Questions
Exam 3: Flow of Control44 Questions
Exam 4: Defining Classes I45 Questions
Exam 5: Defining Classes II46 Questions
Exam 6: Arrays46 Questions
Exam 7: Inheritance43 Questions
Exam 8: Polymorphism and Abstract Classes43 Questions
Exam 9: Exception Handling45 Questions
Exam 10: File IO46 Questions
Exam 11: Recursion44 Questions
Exam 12: Uml and Patterns22 Questions
Exam 13: Interfaces and Inner Classes32 Questions
Exam 14: Generics and the Arraylist Class32 Questions
Exam 15: Linked Data Structures43 Questions
Exam 16: Collections,maps,and Iterators44 Questions
Exam 17: Swing I37 Questions
Exam 18: Swing II31 Questions
Exam 19: Java Never Ends26 Questions
Exam 20: Applets25 Questions
Select questions type
The V parameter in a HashMap< K,V > may be any object,but the K parameter must be a String.
Free
(True/False)
4.7/5
(42)
Correct Answer:
False
The number of entries that may be added to a HashMap< K,V > object is limited to what is specified as the initial capacity in the constructor for the HashMap< K,V > object.
Free
(True/False)
4.7/5
(31)
Correct Answer:
False
Write a Java statement to resize the resulting vector in number 2 above to 100.
Free
(Essay)
4.8/5
(30)
Correct Answer:
v.setSize100);
All of the following are members of Java's Collection class except:
(Multiple Choice)
4.8/5
(34)
Elements of a vector must be of a primitive type,such as int,double,or char.
(True/False)
4.8/5
(40)
If you do not need efficient random access but need to efficiently move sequentially through the list,then use the _____________ class.
(Multiple Choice)
4.8/5
(34)
If you want a class that implements the List interface and do not need any methods beyond those in the List interface,you can use the ____________ class.
(Multiple Choice)
4.7/5
(39)
To use Java's Vector class,you must import the ___________ package.
(Multiple Choice)
4.8/5
(38)
The interface SortedSet and the concrete class _________ is designed for implementations of the Set interface that provide for rapid retrieval of elements.
(Multiple Choice)
4.8/5
(41)
Classes that implement the Set interface allows duplicate elements to occur.
(True/False)
4.8/5
(25)
A ___________ is used to specify a wide range of parameters.
(Multiple Choice)
4.8/5
(45)
The AbstractSequentialList class provides efficient implementation of sequentially moving through the list at the expense of having inefficient implementation of random access to elements.
(True/False)
4.9/5
(35)
When an interface lists a method as "optional," you do not need to implement it when defining a class that implements the interface.
(True/False)
4.8/5
(38)
An Iterator is an object that allows your code to produce the elements in a vector or other container one after the other,exactly once.
(True/False)
4.8/5
(41)
Showing 1 - 20 of 44
Filters
- Essay(0)
- Multiple Choice(0)
- Short Answer(0)
- True False(0)
- Matching(0)