Answer Posted / praveen
Say supposing there is a requirement to store only the
object in an array A.The Primitive types cannot be stored in
the same array as the array can accommodate only Objects
here is where Wrapper Class come into picture.ie, we create
wrapper for the primitive types.One such example is as below
Ex:int i;
Wrapper class for the primitive type(int) is created as below:
INTEGER i = new INTEGER();
Is This Answer Correct ? | 58 Yes | 14 No |
Post New Answer View All Answers
Why scanner is used in java?
What is default constructors?
Can we call virtual funciton in a constructor ?
How do you identify if jvm is 32-bit or 64-bit from java program?
What is the difference between quicksort & mergesort? When should they be used? What is their running time?
What is difference between null and void?
What is thread life cycle in java?
What is type inference in java8?
Why arraylist is not synchronized in java example?
What is codebase?
What is method reference?
How to sort an array from smallest to largest java?
What type of variable is gender?
What is instance means in java?
What is data type in java?