Answer Posted / durga ganesh reddy
autoboxing is that the conversion of primitive data types
into wrapper class objects automatically.By using generic
types of java 1.5,we an acheive it easily.By declaring, the
collection classes as shown below we can do it.
HashSet<Integer> hs=new HashSet<Integer>();
hs.add(1);
hs.add(2);
Iterator it=hs.iterator(0;
while(it.hasNext())
System.out.println(it.next());
| Is This Answer Correct ? | 11 Yes | 0 No |
Post New Answer View All Answers
Is list thread safe in java?
What is mean by collections in java?
What is e java?
Explain the importance of thread scheduler in java?
What is api in java?
What is the purpose of a default constructor?
Is singleton class immutable?
What are the different http methods?
What is the difference between variable & constant?
difference between byte stream class and character stream class?
What is a java applet? What is an interface?
What is the difference between this() and super() in java?
What are recursive functions? Give some examples?
What are some alternatives to inheritance?
What is thread start?