61. What is the remaining capacity of BlockingQueue whose intrinsic capacity is not defined?
62. What will be the output of the following Java code snippet?
public class Test
{
public static void main(String[] args)
{
Set s = new HashSet();
s.add(new Long(10));
s.add(new Integer(10));
for(Object object : s)
{
System.out.println("test - "+object);
}
}
}
public class Test
{
public static void main(String[] args)
{
Set s = new HashSet();
s.add(new Long(10));
s.add(new Integer(10));
for(Object object : s)
{
System.out.println("test - "+object);
}
}
}
63. Where does a new element be inserted in linked list implementation of a queue?
64. Which class provides thread safe implementation of List?
65. Which of these is the interface of legacy?
66. While finding the correct location for saving key value pair, how many times the key is hashed?
67. Which of these package is used for all the text related modifications?
68. Which of these is a Basic interface that all other interface inherits?
69. What will be the output of the following Java code?
import java.util.*;
class hashtable
{
public static void main(String args[])
{
Hashtable obj = new Hashtable();
obj.put("A", new Integer(3));
obj.put("B", new Integer(2));
obj.put("C", new Integer(8));
System.out.print(obj.contains(new Integer(5)));
}
}
import java.util.*;
class hashtable
{
public static void main(String args[])
{
Hashtable obj = new Hashtable();
obj.put("A", new Integer(3));
obj.put("B", new Integer(2));
obj.put("C", new Integer(8));
System.out.print(obj.contains(new Integer(5)));
}
}
70. Which of the below is not an implementation of List interface?
Read More Section(Collections Framework in java)
Each Section contains maximum 100 MCQs question on Collections Framework in java. To get more questions visit other sections.