I am a bgnr java. I read that there is two class in java for string handling. I tried to get its differences but now able to find a satisfying solution. I hope you people can help me out. String class objects can store multiple character and also we can apply string functions for concatenating then the actual size of the string will be get differences . but some where i read that this is the difference Can any body help to get out of this chaos situation.
There is nothing like first reference, second reference. The first or original object being referred by the reference variable "s" will be eligible for garbage collection IF there are NO active references for it. Means, if there are no refernece variables pointing to that object.