Answer Posted / janardhan
yes we can add object in Hashmap
example:--
ArrayList l=new ArrayList();
l.add(10);
HashMap map=new HashMap();
map.put(l,"13");
here l is object
Is This Answer Correct ? | 4 Yes | 0 No |
Post New Answer View All Answers
Is string thread safe in java?
What is identifier give example?
Why scanner is used in java?
What is the function of static in java?
Is 64bit faster than 32 bit?
Why java is object oriented?
What is the difference between procedural and object-oriented programs?
What is the purpose of the enableevents() method in java programming?
Are arrays immutable in java?
what is encapsulation in java? Explain
Explain the difference between the public, private, final, protected, and default modifiers?
What is an off by one error in java?
Explain creating threads by extending thread class ?
How many types of literals are there in JAVA?
What is a void in java?