Answer Posted / manikandan [ gtec,vellore ]
there are different type of data types such as int,char
etc.for example suppose if we using arrays it can store a
similar data types but we need to store a char and int in a
same array what can we do for this situation. the wrapper
class helps in this situation by storing a objects in to a
arrays.
example
ArrayList v=new ArrayList();
v.add(new Integer(1));
v.add(new Character('a'));//
the int and char are different type but we stores it by an
object.
| Is This Answer Correct ? | 2 Yes | 2 No |
Post New Answer View All Answers
What are the three parts of a lambda expression? What is the type of lambda expression?
What is the difference between private & public & friendly classes?
What is java and its types?
What technique is carried out to find out if a particular string is empty?
What is the independent variable in an experiment?
What is the difference between a method and a function in alice?
what do you mean by classloader in java?
Can an unreferenced object be referenced again?
Is arraylist an object in java?
Why there are some null interface in JAVA? What does it mean? Give some null interface in JAVA?
What is a numeric literal?
Can a constructor call the constructor of parent class?
Write a program to find maximum and minimum number in array?
Can we override the static methods?
java program with complete 4 oops concepts implemented example