what is meant by string pooling?
Answer Posted / sivadasan
See,
String s = new String("Shiva");
Its creating two instances and one reference.
In the Two instance one is stored in Constant pool and
another one is stored in temp' pool.
What about String s = "Shiva";
Anybody can, pls clarify...
Is This Answer Correct ? | 4 Yes | 3 No |
Post New Answer View All Answers
What are the parts of a method?
Can a final variable be initialized in constructor?
What is meant by javabeans?
Is it possible to compare various strings with the help of == operator? What are the risks involved?
Is there any difference between synchronized methods and synchronized statements?
What are streams?
What is the basic of java?
Why char array is favored over string for the storage of passwords?
What is string manipulation?
How many types of variables are there?
How to disable caching on back button of the browser?
What is difference between final and finally in java?
What is vector?
Does java linked list allow duplicates?
What is an eror in java?