26 .
Which of the following collection maintain its elements in Natural Sorted order ?
A.LinkedMap
B. LinkedHashMap
C. TreeMap
D.HashMap
View AnswerAns: TreeMap
27 .
Which statement is true about a static nested class?
A.You must have a reference to an instance of the enclosing class in order to instantiate it.
B. it does not have access to non static members of the enclosing class.
C. its variables and method must be static
D.it must extend the enclosing class
View AnswerAns: it does not have access to non static members of the enclosing class.
28 .
Which of these is method for testing whether the specified element is a file or a directory?
A. IsFile()
B. isFile()
C. Isfile()
D. isfile()
View AnswerAns: isFile()
29 .
Which of the following allows us to call generic methods as a normal method?
A.Type Interface
B. Interface
C. Inner class
D.All of the mentioned
View AnswerAns: Type Interface
30 .
If we add Enum constants to a sorted collection ( Treemap , TreeSet ), What will be the order in which they will be maintained ?
A.Sorted Collection wont maintain them in any order.
B. Insertion Order
C. Order in which constants are declared.
D. Natural Sorting Order.
View AnswerAns: Order in which constants are declared.